Jump to content


Photo

Server Status


  • Please log in to reply
3 replies to this topic

#1 ShibSta

ShibSta
  • Members
  • PipPipPip
  • Advanced Member
  • 112 posts

Posted 30 April 2006 - 12:13 PM

I am wanting a server status for the servers of a MMORPG called Lineage II.
I want one similar to [a href=\"http://www.glop.org/lineage2/\" target=\"_blank\"]http://www.glop.org/lineage2/[/a]
However, they're not willing to release the source due to someone who previously took it and made a virus out of it then posted a it on Lineage2.com...
Anyway, does anyone know of a premade class where I can simply edit a page and add the address' and ports?

Reason I ask for a premade one is not only because it's easy but also because I'm a visual learner. I have read a few things on php.net but that just confuses the heck out of me.
Any help is greatly appriciated,
Thanks

#2 greenba

greenba
  • Members
  • PipPipPip
  • Advanced Member
  • 31 posts
  • LocationBosnia and Herzegovina

Posted 30 April 2006 - 01:45 PM

Try to visit:
[a href=\"http://fluttstatus.com/\" target=\"_blank\"]http://fluttstatus.com/[/a]

They have a nice one.

#3 ShibSta

ShibSta
  • Members
  • PipPipPip
  • Advanced Member
  • 112 posts

Posted 30 April 2006 - 09:34 PM

Thanks but thats a bit more than I want, I want a basic one... I got a server status page made and working however how can I make it display a ping?
Site similar: [a href=\"http://www.glop.org/lineage2/\" target=\"_blank\"]http://www.glop.org/lineage2/[/a]
Mine: [a href=\"http://68.68.120.172:5000/status/\" target=\"_blank\"]http://68.68.120.172:5000/status/[/a]

#4 ShibSta

ShibSta
  • Members
  • PipPipPip
  • Advanced Member
  • 112 posts

Posted 01 May 2006 - 11:45 AM

Ok, I found a script I'd like to combine into the one I currently have.
Currently I am using this: [a href=\"http://pastebin.com/692046\" target=\"_blank\"]http://pastebin.com/692046[/a]
To add servers I simply have:
<?php
include 'serverstatus.php';
$test = new status;
$test->AddService('000.000.000.000', 1111, 'name', 'tcp');
$data = $test->GetStatus();
?>
</span>
<table border="0" cellpadding="0" cellspacing="0" class="status">
<tr><td colspan="2" class="top">&nbsp;
</td>
</tr>
<?php
for ($i = 0; $i <= count($data) - 1; $i++) {
    if ($data[$i]['status']) {
        //$img = '<img src="on.gif" width=12 height=12>';
        $img = $on = 'online';
    } else {
        $img = $off ='down';
        // $img = '<img src="off.gif" width=12 height=12>';
    }
    ?>
    <tr>
    <td nowrap class="left">- <strong class="yellow"><?php echo $data[$i]['service'];
    ?></strong></td>
    <td nowrap class="right"><span class="up"><?php echo $img;
    ?></span></td>
    </tr>
    <?php
}
?>

Now I want to combine it with the latency feature of this page.
[a href=\"http://pastebin.com/692050\" target=\"_blank\"]http://pastebin.com/692050[/a]
I am fairly new to this so if someone could practically give me the code I'd appriciate it. I am more of a visual learner by seeing before/after...

I need to get the code into a varible such as $lat or $ping when I run $data = $test->GetStatus();.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users