I am trying to write a shell script which should crawl into a web page and fetch a particular character/phrase from its html and display it. Particular character means, for example if the html of the webpage contains a phrase, say password:blah
, then I want to print the very next character/word to password
, i.e., in short I want the script to print blah
. How can I do this?
If more explanation needed, kindly ask. Thanks in advance!
You don't need a shell script. Probably the following compound command is what you need:
For example, the case of this page works:
Something like that should work:
See man wget for all options.
wget
can download the whole website.