Advertisement
Guest User

Untitled

a guest
Mar 4th, 2015
217
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. <?php
  2.  
  3. $started=microtime(true);
  4. if ($page=file_get_contents($argv[1])) {
  5. if (0.5<(microtime()-$started) && strstr($file, 'some string from page')) {
  6. print "OK";
  7. exit 0;
  8. } else if (strstr($file, 'some string from page')) {
  9. print "WARNING";
  10. exit 1;
  11. }
  12. print "CRITICAL";
  13. exit 2;
  14. }
  15. print "UNKNOWN";
  16. exit 3;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement