You can use the --spider option to not download the file and use the -o
<logfile> to write the wget ouput to a log file. Then parse the log
file and see if it contains a 200 OK response.
Frank
Arthur DiSegna wrote:
Hello,
I have been looking around and haven't found an answer yet...
Is it possible to use WGET to test a website for being up only. I don't want to download any files just test the site for availability? Any ideas?
Psudo code: wget www.google.com. Is connected? YES/NO. If YES write answer to a log. If No write to a log and timestamp it.
Thanks
--
Frank McCown
Old Dominion University
http://www.cs.odu.edu/~fmccown