当前位置 : 主页 > 网页制作 > Dojo >

dojo拼接成CSV格式字符串

来源:互联网 收集:自由互联 发布时间:2021-06-15
var student = "学号,姓名,年龄\n"; for(var i = 0;iresp.items.length;i++) { student += resp.items[i].id + "," + resp.items[i].name + "," + resp.items[i].age + "\n"; } console.info(student);

var student = "学号,姓名,年龄\n";

for(var i = 0;i<resp.items.length;i++)

{

       student += resp.items[i].id + "," + resp.items[i].name + "," + resp.items[i].age + "\n";

}

console.info(student);

网友评论