Display more information
Posted: Sat Aug 18, 2012 5:38 pm
Hi,
I have this PHP that displays server status -
I have this PHP that displays server status -
<html> <head> <style> body{ width: 255px; height: 45px; } </style> </head> <body> <?php /* ##################################### # PlayerCraft - Server status check # ##################################### */ //Change this settings to your servers $server = array( "ip" => "109.70.149.244", "port" => "25565", ); //This is what does the checking, don't care about this code. $check = @fsockopen($server['ip'], $server['port'], $errno, $errstr, 2.5); if (!$check) { //Server was offline echo '<h2 style="color: #ff0000; text-align: center; font-family: arial; font-weight: bold;">OFFLINE</h2>'; } else{ //Server was online echo '<h2 style="color: #008000; text-align: center; font-family: arial; font-weight: bold;">ONLINE</h2>'; } ?> </body> </html>I also have the PHP taken from this websites tutorials, however I was wondering if someone could tell me what i would need to add to the above, to display the player counter?