Вход Регистрация
Файл: region_clean/forum/findyou.php
Строк: 79
<?
#######################################
## Mod By KoT (borispol) [76-75-072] ##
#######################################

require_once "../start.php";
require_once 
"../sid.php";

header('Cache-Control: no-store, no-cache, must-revalidate');
if (
$ver == "wml"header ("Content-type:text/vnd.wap.wml; charset=utf-8");
else 
header("Content-Type:text/html; charset=UTF-8");

require_once 
"../inc.php";
$link connect_db();
list(
$row$id$ps$fsize1$fsize2) = check_login($link);
require_once 
"../version.php";

if (
$ver == "wml") {
echo 
$xml;
echo 
$dtd;
echo 
"<wml>n
      <head><meta http-equiv="
Cache-Control" content="no-cache" forua="true"/></head>n
      <card id="
change" title="Мои темы">n
      <p>n"
;
} else {
echo 
"<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      
<html xmlns="http://www.w3.org/1999/xhtml">
      <
head><link rel="stylesheet" type="text/css" href="../css/$css.css"/>
      <
title>Мои темы</title>
      <
meta http-equiv="Content-Type" content="text/html; charset=utf-8"/></head><body>
      <
div align="left">";
}

$times = getmicrotime();
mysql_query("
Update users set onl='".$times."'room='forum' where id ='".$id."'");
$us = $row['user'];

$date = date("Ymd");

echo '<div class="
c4">Мои темы</div><br/>';

if (empty(
$start)) $start = 0;

$start = intval($start);

if (
$start < 0) $start = 0;

$num_msgs = 10;
$start = intval($start);
$num_msgs = intval($num_msgs);
$arr = mysql_query("select from forum where ((`type`='t') and (`from`='$id'));");
$start = (int)$start;
$num_msgs = (int)$num_msgs;
$q = mysql_query("select from forum where ((`type`='t') and (`from`='$id')) order by `iddesc limit $start,$num_msgs;");
$reg = mysql_num_rows($arr);

echo 'Найдено: '.
$reg.' тем<br/>';
echo 
$divide;

if (mysql_affected_rows() == 0) {
echo 'Нет тем созданных тобой...<br/>';
}
else
{
while (
$field = mysql_fetch_assoc($q)) {
$ref = $field['refid'];
$text = $field['text'];
$from = $field['id'];
$usnick = $field['usnick'];
$id_t = $field['id'];

$from = intval($from);
$ref = intval($ref);
$count_m = mysql_num_rows(mysql_query("SELECT FROM `forumWHERE `type`='m' AND `refid`='".(int)$from."'"));

$rx = mysql_query ("select `textfrom `forumwhere id='".(int)$ref."'");
$arrx = mysql_fetch_array($rx);
$razd = $arrx['text'];

$i = mysql_num_rows($q);
if (
$ver !== "wml") {
echo "
<div class='d1'>";
}
echo 
$razd . "» <a href="index.php?$ses&amp;action=view&amp;fid=".$from."">".$text."</a> (".$count_m.")<br/>";
if (
$ver !== "wml") {
echo '</div>';
}
echo "
- <a href="search.php?$ses&amp;go=view&amp;nick=$us">".col_n($us)."</a><br/><br/>";
}
$i = mysql_num_rows($arr);
echo 
$divide;
if (
$start != 0) {
echo "
<a href="findyou.php?$ses&amp;start=".($start-$num_msgs)."">Пред.стр.</a> | ";
}
else
{
echo 'Пред.стр. | ';
}
if (
$i > $start + $num_msgs) {
echo "
<a href="findyou.php?$ses&amp;start=".($start+$num_msgs)."">След.стр.</a>";
}
else
{
echo 'След.стр.';
}
}

echo '<br/>';
echo "
<div class='d1'><a href="index.php?$ses&amp;ref=$ref">Форум</a><br/>
      <
a href="../enter.php?$ses&amp;ref=$ref">Прихожая</a></div>";

include_once "
../foot.php";
?>
Онлайн: 1
Реклама