Code: Selecteer alles
$sql = "SELECT topic_id, topic_title, topic_last_post_id, topic_time FROM " . TOPICS_TABLE . " WHERE topic_status = 0 AND forum_id != 19 ORDER BY topic_last_post_id DESC LIMIT 0, 10";
if( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not query categories list', '', __LINE__, __FILE__, $sql);
}
$i = 0;
while($i < 10 && $topics = mysql_fetch_row($result))
{
$topicname = $topics[$i]['topic_title'];
$template->assign_vars(array(
'TEST_VAR' => $topicname));
$i++;
}
