Elite Of Caos
Gostaria de reagir a esta mensagem? Crie uma conta em poucos cliques ou inicie sessão para continuar.

Tudo que você sempre quis de um fórum
 
InícioInício  ProcurarProcurar  Últimas imagensÚltimas imagens  RegistarRegistar  Entrar  

 

 Status do server no site

Ir para baixo 
AutorMensagem
mausimag
Informática
Informática
mausimag


Número de Mensagens : 24
Idade : 33
Data de inscrição : 21/12/2007

Status do server no site Empty
MensagemAssunto: Status do server no site   Status do server no site Icon_minitimeSex Dez 21, 2007 11:06 am

Esse aqui vc coloca no seu site:

Código:
<!--.text {font-family: Verdana, Arial, Helvetica,
sans-serif;
font-size:12px;}--></style></head><body><table
border="1" cellspacing="0" cellpadding="5"><tr><td
width="200" colspan="2" align="center" class="text"
bgcolor="#E4E4E4"><strong>SoulRO Server Status
</strong></td></tr><tr><td width="100"
class="text">Login Server</td><td width="100"
class="text"><?php echo $acc_status;
?></td></tr><tr><td width="100"
class="text">Char Server</td><td width="100"
class="text"><?php echo $char_status;
?></td></tr><tr><td width="100"
class="text">Map Server</td><td width="100"
class="text"><?php echo $map_status;
?></td></tr></table></body></html>

Aqui é o arquivo server_status.php, você so vai modicar $host (ip do seu site), $acc_port(porta do char server), $char_port(porta do char server) e $map_port(porta do map server).

Código:
<?php######################################
# Script By Latheesan - Owner of
www.SoulRO.net######################################/*
Configurations */$host = 'psbro.no-ip.info'; // Enter your no-ip.com address
or server ip here.$acc_port = '6900'; // Port number of your Login/Account
Server. Default 6900.$char_port = '6121'; // Port number of your Charater
Server. Default 6121.$map_port = '5121'; // Port number of your Map Server.
Default 5121.$interval = time()+120; // What interval (in seconds) should
this script check server status? To disable, type leave as 0$online =
'On-line'; // Either type the word Online or use <img
src="/images/online.gif" title="Online">$offline = 'Offline'; // Either
type the word Offline or use <img src="/images/offline.gif"
title="Offline">###################################### #
DO NOT EDIT BELOW HERE######################################/*
Disable Error Reporting */error_reporting(0);/* Check Server Status,
If Server Status Was Not Checked In Last $interval seconds
*/if($_COOKIE["checked"] != "true"){/* Check Server Status
*/$acc = fsockopen($host, $acc_port, $errno, $errstr, 1);$char =
fsockopen($host, $char_port, $errno, $errstr, 1);$map = fsockopen($host,
$map_port, $errno, $errstr, 1);/* Workout Server Status & Set Cookie
*/if(!$acc){ $acc_status = $offline; setcookie("acc_status", "offline",
$interval); } else { $acc_status = $online; }if(!$char){ $char_status =
$offline; setcookie("char_status", "offline", $interval); } else { $char_status
= $online; }if(!$map){ $map_status = $offline; setcookie("map_status",
"offline", $interval); } else { $map_status = $online; }/* Set Cookie To
Let The Script Know, Server Status is Checked */setcookie("checked", "true",
$interval);}elseif($_COOKIE["checked"] == "true"){/* Read
Cookie Values */if($_COOKIE["acc_status"] == "offline"){ $acc_status =
$offline; } else { $acc_status = $online; }if($_COOKIE["char_status"] ==
"offline"){ $char_status = $offline; } else { $char_status = $online;
}if($_COOKIE["map_status"] == "offline"){ $map_status = $offline; } else {
$map_status = $online; }}?>
Ir para o topo Ir para baixo
 
Status do server no site
Ir para o topo 
Página 1 de 1
 Tópicos semelhantes
-
» Site de Lista de Servers!
» [Pedido]Site para Download
» LTK Server's
» Criando um Server
» Achando IP do server

Permissões neste sub-fórumNão podes responder a tópicos
Elite Of Caos :: Criação de Servidores :: Server de Ragnarok-
Ir para: