console.show();
//autojs抓取json中的值示例
var text = '{ "sites" : [' + '{ "name":"Runoob" , "url":"www.runoob.com" },' + '{ "name":"Google" , "url":"www.google.com" },' + '{ "name":"Taobao" , "url":"www.taobao.com" } ]}';
objj = JSON.parse(text);
//输出json化的原始内容,不这样做,在处理autojshttpget抓出来的网页源代码会出错
log(objj);
//计算site里有几个子内容的代码
var count = Object.keys(objj.sites).length;
var i=2;
toastLog(count);
toastLog(objj.sites[i].name + " " + objj.sites[i].url);