The online racing simulator
LFS World Server Script
(57 posts, started )
Quote from Drift King CZ :What do you mean? Like this?
<a href="http://www.lfsworld.net/pubstat/live_progress.php?host=MaksNet+%26+SERT+DEMO">MaksNet & SERT DEMO</a>

But I think that weren't on your mind.

This is on my mind.

But, where I need put this code?

In server.php, or _data_inc.php, and where?

Thx.
Ah, I see.

Do you want to put it here as a link on "MaksNet & SERT"? The default link on hostname is like: lfs://|MaksNet%20%26%20SERT|0|S2|/, so you actually want to change this link or am I wrong? I want to know what exactly do you want. This, or add a next other link somewhere else, which will lead to the server status page?
Find in server.php (line 300 in default server.php file)
echo "{$strServer}: <strong><a href=\"lfs://|" . get_clearHostname($output["Name"]) . "|0|" . $output["Version"][0] . $output["Version"][1] . "|/\"" . get_hostname($output["Name"]) . "</a></strong><br />\n";

The whole block looks like this:
// Print out what we did ;-)
echo "<body bgcolor=\"$bgColor\"><font face=\"Verdana\" size=\"2\">";
foreach($server as $output) {
if($output["Version"] == "") {
for($j = 0;$j < $i; $j++) next($server);
echo "{$strServer}: <strong>" . get_hostname(key($server)) . "</strong><br />\n{$strStatus}: <strong><font color=\"#C60000\">{$strOffline}</font></strong><br /><br />\n";
$i++;
}
else {
echo "{$strServer}: <strong><a href=\"lfs://|" . get_clearHostname($output["Name"]) . "|0|" . $output["Version"][0] . $output["Version"][1] . "|/\"" . get_hostname($output["Name"]) . "</a></strong><br />\n";
if($showInfo[0] == 1)
echo "{$strVersion}: " . $output["Version"] . "<br />\n";
if($showInfo[8] == 1)
echo "{$output["Access"]}<br />\n";
if($showInfo[9] == 1)
echo "{$strServerRules}:<br />\n<ul>" . $output["Rules"] . "</ul>\n";
if($showInfo[2] == 1)
echo "{$strTrack}: " . $output["Trackconfig"] . "<br />\n";
if($showInfo[3] == 1)
echo "{$strCars}: " . $output["Cars"] . "<br />\n";
if($showInfo[6] == 1)
echo "{$strRacelength}: " . $output["Laps"] . " " . $output["LapsHours"] . "<br />\n";
if($showInfo[5] == 1) {
if($output["Qualmins"] == '0')
$showQual = $strNone;
else
$showQual = $output["Qualmins"];
echo "{$strQualification}: " . $showQual . "<br />\n";
}
if($showInfo[1] == 1)
echo "{$strPlayersConnected}: " . $output["PlayersOn"] . "/" . $output["MaxPlayers"] . "<br />\n";
if($showInfo[7] == 1) {
if($output["Racers"] == '')
$showRacers ="  {$strNone}";
else
$showRacers = $output["Racers"];
echo "{$strRacersOnline}:<br />". $showRacers . "\n";
}
echo "<br /><br />";
$i++;
}
}

Replace the line 300 with
echo "{$strServer}: <strong><a href=\"http://www.lfsworld.net/pubstat/live_progress.php?host=" . get_clearHostname($output["Name"]) . "\">" . get_hostname($output["Name"]) . "</a></strong><br />\n";

If you want the link open in a new window or panel, replace with
echo "{$strServer}: <strong><a href=\"http://www.lfsworld.net/pubstat/live_progress.php?host=" . get_clearHostname($output["Name"]) . "\" target=\"_blank\">" . get_hostname($output["Name"]) . "</a></strong><br />\n";

If you want, you can post here code of your server.php file and I will do it.
// Print out what we did ;-)
echo "<body bgcolor=\"$bgColor\" style=\"color: #A7A7A7;\"><font face=\"Verdana\" size=\"1\">";
foreach($server as $output) {
if($output["Version"] == "") {
for($j = 0;$j < $i; $j++) next($server);
echo "{$strServer}: <strong>" . get_hostname(key($server)) . "</strong><br />\n{$strStatus}: <strong><font color=\"#C60000\">{$strOffline}</font></strong><br /><br />\n";
$i++;
}
else {
echo "{$strServer}: <strong>" . get_hostname(key($server)) . "</strong><br />\n";
if($showInfo[0] == 1)
echo "{$strVersion}: " . $output["Version"] . "<br />\n";
if($showInfo[8] == 1)
echo "{$output["Access"]}<br />\n";
if($showInfo[9] == 1)
echo "{$strServerRules}:<br />\n<ul>" . $output["Rules"] . "</ul>\n";
if($showInfo[2] == 1)
echo "{$strTrack}: " . $output["Trackconfig"] . "<br />\n";
if($showInfo[3] == 1)
echo "{$strCars}: " . $output["Cars"] . "<br />\n";
if($showInfo[6] == 1)
echo "{$strRacelength}: " . $output["Laps"] . " " . $output["LapsHours"] . "<br />\n";
if($showInfo[5] == 1) {
if($output["Qualmins"] == '0')
$showQual = $strNone;
else
$showQual = $output["Qualmins"];
echo "{$strQualification}: " . $showQual . "<br />\n";
}
if($showInfo[1] == 1)
echo "{$strPlayersConnected}: " . $output["PlayersOn"] . "/" . $output["MaxPlayers"] . "<br />\n";
if($showInfo[7] == 1) {
if($output["Racers"] == '')
$showRacers ="  {$strNone}";
else
$showRacers = $output["Racers"];
echo "{$strRacersOnline}:<br />". $showRacers . "\n";
}
echo "<br /><br />";
$i++;
}
}

Pls.
Is there anyway to show if a server is in s1/s2/demo mode??

LFS World Server Script
(57 posts, started )
FGED GREDG RDFGDR GSFDG