This post has already been read 1459 times!
- We can use Python urllib to get website content in python program.
- We can also use it to call REST web services.
- We can make GET and POST http requests.
- This module allows us to make HTTP as well as HTTPS requests.
- We can send request headers and also get information about response headers.
read() method returns the byte array. Above code will print the HTML data returned by the Wikipedia home page. It will not be in human readable format, but we can use some HTML parser to extract useful information from it.