Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

wget download for offline viewing including absolute references

Tags:

wget

I'm trying to download an entire webpage using the following command

wget -p -k www.myspace.com/

This does download the page and any images or scripts under that directory, but I'm trying to figure out how to download that page for completely offline viewing. How would I get every image, script, and style sheet linked within the source for www.myspace.com including external links?

like image 723
brandon Avatar asked Feb 20 '23 07:02

brandon


1 Answers

wget -e robots=off -H -p -k http://www.myspace.com/

The -H or --span-hosts flag is necessary for a complete mirror, as the page is likely to include content on hosts outside the www.myspace.com domain. Ignore robots for good measure.

like image 118
dongle Avatar answered May 01 '23 02:05

dongle