Файл: accmarket.net/game/plusres.php
Строк: 21
<?php
define('_ON_CMS', 1);
require_once '../includes/start.php';
require_once '../includes/function.php';
require_once '../includes/header.php';
if($game==0 OR $level==0 OR $ban!=0){
header('Location: ../index.php');
}
$r=$_GET['r'];
$q = mysql_query("SELECT * FROM `planet` WHERE `id`='".check(mysql_real_escape_string($pl))."'");
$f = mysql_fetch_array($q);
if(res($r)!=''){
switch ($act) {
default:
echo '<div class="top">'.res(check($r)).'</div>';
$allres = mysql_result(mysql_query("SELECT SUM(res) FROM `planet_loc` WHERE `uid`='".$use_id."' AND `occupy`=0 AND `type`='".check($r)."';"), 0);
$allrab = mysql_result(mysql_query("SELECT SUM(rab) FROM `planet_loc` WHERE `uid`='".$use_id."' AND `occupy`=0 AND `type`='".check($r)."';"), 0);
echo '<div class="conts">'.res(check($r)).' (запас): '.$allres.' ед.<br/>
'.rab($rasa).' на добыче: '.$allrab.'
</div>';
break;
}}
div('<a href="../">В игру</a>','conts');
require_once '../includes/footer.php';
?>