{% else-1 %}
(12 апр 2013, 16:07) (0/0) [0]
Сергей82, Там где смайлик,там скобка )
(12 апр 2013, 16:05) (0/0) [0]
[php]$req = mysql_query(\"SELECT * FROM `forum` WHERE `type` = \'t\' AND `close` != \'1\' ORDER BY `time` DESC LIMIT 5\"*;
if (mysql_num_rows($req)) {
for ($i = 0; $res = mysql_fetch_assoc($req); ++$i) {
$q3 = mysql_query(\"select `id`, `refid`, `text` from `forum` where type=\'r\' and id=\'\" . $res[\'refid\'] . \"\' LIMIT 1\"*;
$razd = mysql_fetch_assoc($q3);
$q4 = mysql_query(\"select `id`, `refid`, `text` from `forum` where type=\'f\' and id=\'\" . $razd[\'refid\'] . \"\' LIMIT 1\"*;
$frm = mysql_fetch_assoc($q4);
$nikuser = mysql_query(\"SELECT `from`, `time` FROM `forum` WHERE `type` = \'m\' AND `close` != \'1\' AND `refid` = \'\" . $res[\'id\'] . \"\'ORDER BY `time` DESC\"*;
$colmes1 = mysql_num_rows($nikuser);
$cpg = ceil($colmes1 / $kmess);
$nam = mysql_fetch_assoc($nikuser);
echo $i % 2 ? \'<div class=\"list2\">\' : \'<div class=\"list1\">\';
// Значки
$icons = array(
($res[\'vip\'] ? \'<img src=\"../theme/\' . $set_user[\'skin\'] . \'/images/pt.gif\" alt=\"\"/>\' : \'\'),
($res[\'realid\'] ? \'<img src=\"../theme/\' . $set_user[\'skin\'] . \'/images/rate.gif\" alt=\"\"/>\' : \'\'),
($res[\'edit\'] ? \'<img src=\"../theme/\' . $set_user[\'skin\'] . \'/images/tz.gif\" alt=\"\"/>\' : \'\')
);
echo functions::display_menu($icons, \'&#160;\', \'&#160;\');
echo \'<a href=\"index.php?id=\' . $res[\'id\'] . \'\">\' . $res[\'text\'] . \'</a>&#160;[\' . $colmes1 . \']\';
if ($cpg > 1)
echo \'&#160;<a href=\"index.php?id=\' . $res[\'id\'] . \'&amp;clip&amp;page=\' . $cpg . \'\">&gt;&gt;</a>\';
echo \'<br/><div class=\"sub\"><a href=\"index.php?id=\' . $razd[\'id\'] . \'\">\' . $frm[\'text\'] . \'&#160;/&#160;\' . $razd[\'text\'] . \'</a><br />\';
echo $res[\'from\'];
if (!empty($nam[\'from\'])) {
echo \'&#160;/&#160;\' . $nam[\'from\'];
}
echo \' <span class=\"gray\">\' . date(\"d.m.y / H:i\", $nam[\'time\']) . \'</span>\';
echo \'</div></div>\';
}
} else {
echo \'<div class=\"menu\"><p>\' . $lng[\'list_empty\'] . \'</p></div>\';
}
echo \'<div class=\"phdr\"><a href=\"index.php\">\' . $lng[\'to_forum\'] . \'</a></div>\';
}[/php]
  • 1 из 1