i=0
方法一:
urllib.urlretrieve(url, 文件名 + “.jpg”)
方法二:
for url in listurl:
f = open(str(i)+’.jpg’, ‘w’)
req = urllib2.urlopen(url)
buf = req.read()
f.write(buf)
i+=1
f.close()
i=0
方法一:
urllib.urlretrieve(url, 文件名 + “.jpg”)
方法二:
for url in listurl:
f = open(str(i)+’.jpg’, ‘w’)
req = urllib2.urlopen(url)
buf = req.read()
f.write(buf)
i+=1
f.close()