PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Hey guys, I was wondering if anyone could write me a short script. I just want to simply check to see if a server is running. I was told to use fsockopen() on a different forum, but I could never figure out how to get it to work. It works when the server is online, but when it is offline, it throws me a bunch of errors and warnings. How can I get rid of those, and just simply display "server is offline" ?? Thanks in advance!
You know, I asked the same question a few months ago, I knew it somehow suppressed errors, but I wasn't sure if it was supposed to do that or if it was just a hack.