This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import requests | |
| referers = [ | |
| '', | |
| 'https://www.v2ex.com/', | |
| 'https://www.xxoo.com/', | |
| 'https://www.google.com/', | |
| 'http://www.baidu.com/', | |
| 'http://www.sogou.com/', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #coding: utf-8 | |
| import sys | |
| reload(sys) | |
| sys.setdefaultencoding('utf-8') | |
| import requests | |
| url = 'http://pan.baidu.com/share/link?shareid=1268793885&uk=2989926935' | |
| r = requests.get(url) | |
| print len(r.text) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #doubansite.py | |
| #抓取豆瓣音乐人小站的音乐并下载 | |
| #2013/09/20 | |
| import requests | |
| import re | |
| import os | |
| import json | |
| def GETdata(): |
NewerOlder