Файл: soc-set/moduls/fermer/index3.php
Строк: 63
<?php
include_once '../sys/inc/start.php';
include_once '../sys/inc/compress.php';
include_once '../sys/inc/sess.php';
include_once '../sys/inc/home.php';
include_once '../sys/inc/settings.php';
include_once '../sys/inc/db_connect.php';
include_once '../sys/inc/ipua.php';
include_once '../sys/inc/fnc.php';
include_once '../sys/inc/user.php';
$set['title']='Веселый фермер!';
error_reporting (0);
include_once '../sys/inc/thead.php';
title();
err();
aut();
//header("Content-type: application/vnd.wap.xhtml+xml");
header("Content-type: text/html");
if (isset($user)){
$dog = mysql_result(mysql_query("select count(*) from `fermer_dog` WHERE `id_user` = '$user[id]' LIMIT 1"),0);
if($dog==0){
mysql_query("INSERT INTO `fermer_dog` (`id_user`,`time`) VALUES ($user[id],NULL) ");
mysql_query("UPDATE `user` SET `fermer_doggy`='0' WHERE `id`='id_user'");
}
$post = mysql_result(mysql_query("select count(*) from `fermer_gr` WHERE `id_user` = '$user[id]' LIMIT 1"),0);
if($post<5){
mysql_query("INSERT INTO `fermer_gr` (`kol`,`semen`, `id_user`) VALUES ( NULL, '0', '".$user['id']."') ");
mysql_query("INSERT INTO `fermer_gr` (`kol`,`semen`, `id_user`) VALUES ( NULL, '0', '".$user['id']."') ");
mysql_query("INSERT INTO `fermer_gr` (`kol`,`semen`, `id_user`) VALUES ( NULL, '0', '".$user['id']."') ");
mysql_query("INSERT INTO `fermer_gr` (`kol`,`semen`, `id_user`) VALUES ( NULL, '0', '".$user['id']."') ");
mysql_query("INSERT INTO `fermer_gr` (`kol`,`semen`, `id_user`) VALUES ( NULL, '0', '".$user['id']."') ");
}
echo "<link rel='stylesheet' href='style.css' type='text/css' /><center><div class='grad32'><img src='fermer.gif'></div><div class='grad16'>Форум</div></center><div class='ferm3'>";
echo "<a href='../forum/new_t.php'><img src='egg.png'> Новые темы</a><br/>";
echo "<a href='../forum/search.php'><img src='egg.png'> Поиск по форуму</a><br/>";
echo "<a href='../forum/new_p.php'><img src='egg.png'> Популярные темы</a><br/>";
echo "<a href='../forum'><img src='egg.png'> В форум</a><br/>";
echo "<a href='index.php'><img src='egg.png'> В игру</a><br/>";
}else{
echo '<div class="msg">Ферма доступна только для авторизованных пользователей!</div>';};
include_once '../sys/inc/tfoot.php';
?>