Jump to content

Recommended Posts

  • 1 month later...
Posted (edited)

Put this in your site

<?php include "config/config.php" ?> 
<?php

    //if ($server && $port && $timeout) {
        $game =  @fsockopen("$server", $portg, $errno, $errstr, $timeout);
        $login =  @fsockopen("$server", $portl, $errno, $errstr, $timeout);
    //}
    if($login) {
        echo "<p style='margin-top: 15px;'>Login: <font color=#00DF00>Online</font><br /></p>";
    }
    else {
        echo "<p>Login: <font color=#FF0000>Offline</font><br /></p>";
    }
    if($game) {
        echo "<p>Game: <font color=#00DF00>Online</font><br /></p>";
    }
    else {
        echo "<p>Game: <font color=#FF0000>Offline</font><br /></p>";
    }
    echo "";
?>

and config.php file looks like this


<?php
    $server  = "yourserver.eu"; //you can put ip adress or domain name
    $portg   = "7777";
    $portl   = "2106";
    $timeout = "1";
?>

Edit....

Remember that the first part of code need to be placed in php file. ;)
 

Edited by yaotzi9n

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..