<?php
/**************************************************************************************************
| Software Name : Ravan Scripts Online Mafia Game
| Software Author : Ravan Soft Tech
| Software Version : Version 2.0.1 Build 2101
| Website : http://www.ravan.info/
| E-mail : support@ravan.info
|**************************************************************************************************
| The source files are subject to the Ravan Scripts End-User License Agreement included in License Agreement.html
| The files in the package must not be distributed in whole or significant part.
| All code is copyrighted unless otherwise advised.
| Do Not Remove Powered By Ravan Scripts without permission .
|**************************************************************************************************
| Copyright (c) 2010 Ravan Scripts . All rights reserved.
|**************************************************************************************************/
include "globals.php";
print "";
$cn=0;
$q=$db->query("SELECT * FROM users WHERE laston>unix_timestamp()-15*60 ORDER BY laston DESC");
print"
<div class='generalinfo_txt'>
<div><img src='images/info_left.jpg' alt='' /></div>
<div class='info_mid'><h2 style='padding-top:10px;'>ПОТРЕБИТЕЛИ ОНЛАЙН</h2></div>
<div><img src='images/info_right.jpg' alt='' /></div> </div>
<div class='generalinfo_simple'><br /><br /><br />";
print "<table width='98%'class='table' border='0'><tr style='background:gray'><th>ID</th><th>Играч</th><th>Ниво</th><th>Пол</th><th>Последно посещение</th><th>Долари</th><th>Атака ?</th>";
while($r=$db->fetch_row($q))
{
$la=time()-$r['laston'];
$unit="секунди";
if($la >= 60)
{
$la=(int) ($la/60);
$unit="минути";
}
if($la >= 60)
{
$la=(int) ($la/60);
$unit="часа";
if($la >= 24)
{
$la=(int) ($la/24);
$unit="дни";
}
}
if($r['laston'] > 0)
{
$la=time()-$r['laston'];
$unit="секунди";
if($la >= 60)
{
$la=(int) ($la/60);
$unit="минути";
}
if($la >= 60)
{
$la=(int) ($la/60);
$unit="часа";
if($la >= 24)
{
$la=(int) ($la/24);
$unit="дни";
}
}
$str="преди $la $unit";
}
else
{
$str="--";
}
if($r['last_login'] > 0)
{
$ll=time()-$r['last_login'];
$unit2="секунди";
if($ll >= 60)
{
$ll=(int) ($ll/60);
$unit2="минути";
}
if($ll >= 60)
{
$ll=(int) ($ll/60);
$unit2="часа";
if($ll >= 24)
{
$ll=(int) ($ll/24);
$unit2="дни";
}
}
$str2="преди $la $unit";
}
else
{
$str2="--";
}
$money=money_formatter($r['money']);
$cn++;
print"
</tr>
<td><div align='center'><strong>
{$r['userid']}
</strong></div></td>
<td><div align='center'><strong>
<a href='viewuser.php?u={$r['userid']}'>{$r['username']}
</strong></div></td>
<td><div align='center'><strong>
{$r['level']}<br />
</div></strong></td>
<td><div align='center'><strong>
{$r['gender']}<br />
</div></strong></td>
<td><div align='center'><strong>
$str<br />
</div></strong></td>
<td><div align='center'><strong>
$money</a><br />
</div></strong></td>
<td><div align='center'><strong>
<a href='attack.php?ID={$r['userid']}'>ДАВАЙ!</a><br />
</div></strong></td>
";
}
print "</table></div><div><img src='images/generalinfo_btm.jpg' alt='' /></div><br /></div></div></div></div></div>";
$h->endpage();
?>