This topic created in 4737 days ago, the information mentioned may be changed or developed.
下面是代码
```CODE
import urllib.request
url="http://www.oschina.net"
req_header = {'User-Agent':'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11',
}
req = urllib.request.Request(url,None,req_header)
resp = urllib.request.urlopen(req)
html = resp.read().decode('utf8','ignore')
print(html)
```