2011-12-23, 06:39 PM
Hello
Anyone know? i have succefuly to get latest thread forum 1 into site.
Now how to get the second forum as the code is. let says forum 1 is lynx and second muka. what i have to do?
thx
Anyone know? i have succefuly to get latest thread forum 1 into site.
Now how to get the second forum as the code is. let says forum 1 is lynx and second muka. what i have to do?
Quote:<?php
chdir("lynx/"); // path to MyBB
define("IN_MYBB", 1);
require("./global.php");
$tlimit = 5; // How many titles you want
$query = $db->query("SELECT * FROM ".TABLE_PREFIX."threads ORDER BYtid
DESC LIMIT $tlimit");
$list = '';
while($fetch = $db->fetch_array($query))
{
$list .= " | <strong><a href=\"lynx/showthread.php?tid={$fetch['tid']}\" target=\"_blank\">".htmlspecialchars_uni($fetch['subject'])."</a></strong>";
/*
$poster = "<a href=\"forum/member.php?action=profile&uid=".$fetch['uid']."\">{$fetch['username']}</a>";
$list .= "Created by: {$poster} ";
$list .= "<i>" .$fetch['replies']. " Replies</i>";
$list .= "<i> , " .$fetch['views']. " Views</i> ";
$list .= " (<i>Last post by: " .$fetch['lastposter']. "</i>)<br /><hr width=\"50\"><br />";
*/
}
//output
echo $list;
?>
thx