Код:
<?php
if (eregi("block-Content.php", $_SERVER['PHP_SELF'])) {
Header("Location: index.php");
die();
}
global $prefix, $db;
$result = $db->sql_query("SELECT pid, title, cid FROM " . $prefix . "_pages WHERE active='1'");
while ($row = $db->sql_fetchrow($result)) {
$pid = intval($row['pid']);
$cid = intval($row['cid']);
$title = filter($row['title'], nohtml);
$result2 = $db->sql_query("SELECT title FROM " . $prefix . "_pages_categories WHERE cid=$cid");
$row2 = $db->sql_fetchrow($result2);
$title_cat = filter($row2['title'], nohtml);
$content .= "<strong><big>·</big></strong> <b>$title_cat </b><br> <a href=\"modules.php?name=Content&pa=showpage&pid=$pid\">-$title</a><br>";
}
?>