Jump to content

Site online check script


haro

Recommended Posts

Hi,

 

I know there are several services to check if your site is available/online. But I would like to implement myself such a site monitor/check script.

 

Because only a check if the server is available does not detect if your cms gives an error message or if there is something wrong with dns, I would prefer a method where I add a certain string in the first part of the html of the homepage and then the script should check every hour or so if that word/string is still present and if not (which would mean site offline) send an email alert.

 

How would I do this in php? I know the easy parts like how to set cron to run the script every hour and know how to let php send emails, but how could I from another site open a page and check for a word/string if its present?

 

Thanks,

 

Hans

 

Link to comment
https://forums.phpfreaks.com/topic/205248-site-online-check-script/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.