and other concluding words. , but there is no code in the upper part such as . I hope someone can help me. Thank you. The code is as follows:
import urllib2
resp = urllib2.urlopen("http://www.baidu.com")
print resp.read()
Get the web page as follows (beginning and end):
The code is fine, the problem is the command window. resp.read() obtains all the content, but the command window is not fully displayed.
python test.py > res.txt Output to file for viewing