Register for your free account! | Forgot your password?

You last visited: Today at 22:46

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Server Status

Discussion on Server Status within the Rappelz Private Server forum part of the Rappelz category.

Reply
 
Old   #1
 
Pyrochina's Avatar
 
elite*gold: 0
Join Date: May 2013
Posts: 43
Received Thanks: 1
Server Status

Hi! I was just wondering how to add a server status to a site.

I would want it like this

Log In: ON (or if it's off) OFF

Rappelz Server: ON (or if it's off) OFF
Teampeak: ON (or if it's off) OFF
Pyrochina is offline  
Old 06/03/2013, 22:48   #2
 
elite*gold: 0
Join Date: Jul 2011
Posts: 111
Received Thanks: 86
Something like this ?

Code:
<?php

$ip= "127.0.0.1"; //Server IP
$port= "6686"; //Server Port

@$fp = fsockopen ($ip ,$port , $errno, $errstr, 1);
if (!$fp)
echo '<b>Server:<font color="#FF0000"><b> Offline</b></font></b>';

else
echo '<b>Server:<font color="#008000"><b> Online</b></font></b>';

?>
Ne0@NCarbon is offline  
Old 06/03/2013, 23:53   #3
 
Pyrochina's Avatar
 
elite*gold: 0
Join Date: May 2013
Posts: 43
Received Thanks: 1
Yes but that works...
Pyrochina is offline  
Old 06/04/2013, 12:11   #4
 
elite*gold: 0
Join Date: Apr 2012
Posts: 463
Received Thanks: 837
You don't have to close $fp ? If it's not done automatically, you will have a bunch of opened connection to the game server never closed especially if many people use this web page. (even if the server will close them after a while)

(using fclose($fp) when online )
glandu2 is offline  
Old 06/11/2013, 01:47   #5
 
elite*gold: 0
Join Date: Jun 2013
Posts: 31
Received Thanks: 3
Pyrochina... I gave you my skype by PM I'll give you the codes to an old site I coded. You can see some functions and others. Also, you can also try to use online tutorials to help you learn more
Dyson49 is offline  
Old 06/20/2013, 15:24   #6
 
neaw's Avatar
 
elite*gold: 0
Join Date: Jun 2013
Posts: 4
Received Thanks: 0
@Ne0 :
Code:
<?php

$ip= "127.0.0.1"; //Server IP
$port= "6686"; //Server Port

@$fp = fsockopen ($ip ,$port , $errno, $errstr, 1);
if (!$fp){
     echo '<b>Server:<font color="#FF0000"><b> Offline</b></font></b>';
     fclose($fp);
}
else
     echo '<b>Server:<font color="#008000"><b> Online</b></font></b>';

?>
you still have the handle active on socket
neaw is offline  
Reply


Similar Threads Similar Threads
Reg Page Edited Server Status + Extra Status
08/26/2012 - SRO Coding Corner - 22 Replies
This is a new realease of the reg page created by Xsense Download XAMP apache friends - xampp for windows Reg Page Files (By Tazdingo And Xsense) : Multiupload.com - upload your files to multiple file hosting sites! 1. Install XAMP 2. Go to the PHP folder of the xampplite (C:\xampplite\php) and search PHP.ini 3. In the PHP.ini search ;extension=php_mssql.dl and delete ";"
[Server Status] Server Status Programs From A Couple Servers.
11/05/2008 - Conquer Online 2 - 9 Replies
Hey i dont know in what section to post it so i hope that the mods will move it to the good section but i made this server status program i will make later more server status programs for other servers. PhoenixCo: Server Checker Qonquer Qonquer Server Checker Screenshot: http://i286.photobucket.com/albums/ll115/aschwinh /sdfsdfsdf.jpg



All times are GMT +2. The time now is 22:46.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.