How to create a "live server monitor" (Whatever it is)
#1

I saw alot of websites with these server monitors, which was showing stuff about the server live. Then i was wondering how to create one. Anyone of you know? Please tell, if you do ofcourse.
Reply
#2

you need to learn php
and second:
http://docs.typefish.co.uk/samp/php/query/
Reply
#3

You need to code one

Look at www.gametracker.rs

They coded it
Reply
#4

All you need is:
Code:
<?php

$aPlayers = $query->getDetailedPlayers();

if(!is_array($aPlayers) || count($aPlayers) == 0)
{
echo '<br /><i>None</i>';
}
else
{
?>
<table width="400">
<tr>
<td><b>Player ID</b></td>
<td><b>Nickname</b></td>
<td><b>Score</b></td>
<td><b>Ping</b></td>
</tr>
<?php
foreach($aPlayers as $sValue)
{
?>
<tr>
<td><?= $sValue['playerid'] ?></td>
<td><?= htmlentities($sValue['nickname']) ?></td>
<td><?= $sValue['score'] ?></td>
<td><?= $sValue['ping'] ?></td>
</tr>
<?php
}

echo '</table>';
}
}
?>
and http://files.typefish.co.uk/sa-mp/SampQueryAPI.php

+ fsockopen() has to be enabled - contact your host and ask them to enable it.
Reply
#5

THanks guys.


** LOCK **
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)