伤疤也微笑 发表于 2013-8-2 15:40:37

求助提取图片并批量下载

求助批量下载以下代码中红色图片!
var arrPic = [], list = $$("idList"), image = $$("idImage");
arrPic.push({ smallPic: '<a rel="nofollow" href="http://product.pconline.com.cn/pdlib/523209_bigpicture7939726.html" target="_blank"><img width="58" height="43" src="http://img.pconline.com.cn/images/product/5203/520317/s400_3_s.jpg" />前视</a>', originPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_3_m.jpg", zoomPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_3.jpg" });
arrPic.push({ smallPic: '<a rel="nofollow" target="_blank" href="http://product.pconline.com.cn/pdlib/523209_bigpicture7939724.html"><img width="58" height="43" src="http://img.pconline.com.cn/images/product/5203/520317/s400_1_s.jpg" />正视</a>', originPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_1_m.jpg", zoomPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_1.jpg" });
arrPic.push({ smallPic: '<a rel="nofollow" target="_blank" href="http://product.pconline.com.cn/pdlib/523209_bigpicture7939725.html"><img width="58" height="43" src="http://img.pconline.com.cn/images/product/5203/520317/s400_2_s.jpg" />侧视</a>', originPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_2_m.jpg", zoomPic: "http://img.pconline.com.cn/images/product/5203/520317/s400_2.jpg" });
arrPic.push({ smallPic: '<a rel="nofollow" target="_blank" href="http://product.pconline.com.cn/pdlib/523209_bigpicture8168251.html"><img width="58" height="43" src="http://img.pconline.com.cn/images/product/5232/523209/s400_8_s.jpg" />俯视</a>', originPic: "http://img.pconline.com.cn/images/product/5232/523209/s400_8_m.jpg", zoomPic: "http://img.pconline.com.cn/images/product/5232/523209/s400_8.jpg" });
list.innerHTML = "";
$$A.forEach(arrPic, function(o, i){
var li = list.appendChild(document.createElement("LI"));

黄毛丫头 发表于 2013-8-3 16:13:38

建立标签,选择循环匹配来采集

DZH_report 发表于 2013-8-6 09:10:22

这个不难,QQ:121591481

wxl08 发表于 2013-8-6 10:20:22

页: [1]
查看完整版本: 求助提取图片并批量下载