08-03-2004, 05:46 PM
What is the best way to check for dead links? I currently use a PHP script that you type in the URL and it checks it out and returns all sorts of data that I really don't need. What I would like to be able to do is check all the links on an HTML document without typing each one in separately. The first idea I thought of would be to use PHP to pull the HTML document in and gather up all the links and check to see if each one is valid. I would only want it to report any dead links not ones that are ok. This might be to intensive though for the server so my second idea would be to check the server log file(s) to see if anything there would indicate a dead link. Can you give me some advice on the best way to go about doing this and some resources or sample scripts that I could use to do this? Thank you.