- Joined
- Feb 13, 2009
- Messages
- 552
- Reaction score
- 56
I used search function but didn't find it! I really need this on my server main page! Thanks in advance!
Thanks mate much helpful!
<?php
$conf_gmt=0; //Correction for GMT, the time when the web server is different from time to time on the game server. If time is the same - specify 0
$conf_ygmt=2; //YOUR GMT zone. Ukraine +2, Russia +3
$conf_cw1=5; //1st CW
$conf_cw2=13; //2nd CW
$conf_cw3=21; //3rd CW
$h=Date(H);
$datem=date(i);
$h=$h+$conf_gmt;
if ($h>=25) {
$h=$h-24;
}
if($h < $conf_cw2 && $h >= $conf_cw1)
{ $hh=2;$hc=$conf_cw2; }
if($h >= $conf_cw2 && $h < $conf_cw3)
{ $hh=3;$hc=$conf_cw3; }
if($h >= $conf_cw3 && $h <= 23)
{ $hh=1;$hc=$conf_cw1; }
if($h >= 00 && $h < $conf_cw1)
{ $hh=1;$hc=$conf_cw1; }
if($h >= $conf_cw1 && $h <= $conf_cw2)
{ $hh=2;$hc=$conf_cw2; }
if ($h==24)
{ $hh=1;$hc=$conf_cw1; }
if ($h==0)
{ $hh=1;$hc=$conf_cw1; }
$inh=($hc-$h)-2;
$inm=60-$datem;
$chipwar1="<div>".$hh." ChipWar at ".$hc.":00<br>";
$chipwar3="Time left: ".$inh.":".$inm."<br>Server time: ".$h.":".$datem."<br>(GMT +".$conf_ygmt.")<br><br>".$conf_cw1.":00 - ".$conf_cw2.":00 - ".$conf_cw3.":00</div>";
$chipwar=$chipwar1.$chipwar3;
echo $chipwar;
?>
I wish i could put this scrip on my page, when some one join to my page ( they see the status ), some one could help me with that ? thanks.
Ok I'm running xampp really new to .php stuff anyone have a simple guide where to put it ?
OK found the php area in xampp... so I that this php and paste it to notepad ?
read what fyurith said at the top... just copy it and ssave it with exention of .php then put it to your webfiles..
Cool very nice rapido15
Thanks, but i want that my CW status show it on my webpage, likes this
Well I have a main page and a forums but can't figure out xampp, appserver is so much easier!
<?php
echo "test crap";
?>