A script to fetch HTML

I'd recommend doing this in Python, a clean, elegant language with suitable libraries for the task (for example, the requests library). Here's the code to fetch the HTML from a page:

Code:
import requests

# ...

r = requests.get(url)
print r.text

If you're looking to parse the HTML further, BeautifulSoup and Scrapy are well up to the task.
 
Back
Top