Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
05-23-2011, 12:06 AM #1
- Join Date
- May 2011
- Thanked 0 Times in 0 Posts
Check if Server is online or offline?
Do I post this here? Haha, have no idea which.
I play a game called terraria. And I wanted to see make a server list. But I have no way of knowing if a server is online or offline. Is there a way to make a script to check then have a picture if its online or offline?
05-23-2011, 12:13 AM #2
- Join Date
- Feb 2011
- Your Monitor
- Thanked 525 Times in 512 Posts
- Blog Entries
Yes there are several ways. If the server has a http server then you can perform a call to a page or file and check for a 200 status code, you can attempt to connect to a port, you can ping it...
There are many ways to see if a server is up and running, you just have to decide what suits you best.
See my new CodingForums Blog: http://www.codingforums.com/blogs/tangoforce/
Many useful explanations and tips including: Cannot modify headers - already sent, The IE if (isset($_POST['submit'])) bug explained, unexpected T_CONSTANT_ENCAPSED_STRING, debugging tips and much more!