PHP Code:
$latestconfession = $DB_site->query_first ("
SELECT COUNT(*) AS votes, confessions.confessionid, confessions.visible,
confessions.text, confession_rate.rate, user.username
FROM confessions
LEFT JOIN confession_rate ON (confessions.confessionid = confession_rate.confessionid)
LEFT JOIN user ON (user.userid = confessions.userid)
WHERE confessions.visible = 1
GROUP BY confessions.confessionid
ORDER BY confessions.confessionid DESC
LIMIT 1
");
$latestconfession_info = $DB_site->fetch_array($latestconfession);
$latestconfession_info['text'] = nl2br(stripslashes($latestconfession_info['text']));
if (strlen($latestconfession_info[text]) > 150)
{
$latestconfession_info['text'] = substr($latestconfession_info['text'],0,150)."...";
}
$latestconfession_info_text = "$latestconfession_info[text]";
$latestconfession_info['num_rates'] = number_format($latestconfession_info['votes']);
extract($latestconfession_info);
eval('$siteindex_contentbox .= "' . fetch_template("siteindex_confessions") . '";');
the problem is that $latestconfessions_info_text isn't eachoing out into the template