<?php
$limit = 5;
//$forumpath = 'forum/';
define("IN_MYBB", 1);
require('./global.php');
$unviewable = get_unviewable_forums();
if($unviewable)
{
$unview = "AND fid NOT IN ({$unviewable})";
}
$query = $db->simple_select('threads', '*', "1=1 {$unview} ORDER BY tid DESC LIMIT {$limit}");
if($db->num_rows($query) > 0)
{
while($row = $db->fetch_array($query))
{
$date = my_date($mybb->settings['dateformat'], $row['lastpost'], "", 1);
$time = my_date($mybb->settings['timeformat'], $row['lastpost'], "", 1);
echo "<a href=\"{$forumpath}showthread.php?tid={$row['tid']}\">{$row['subject']}</a> -
Inviato da: <a href=\"{$forumpath}member.php?action=profile&uid={ $row['lastposteruid']}\">{$row['lastposter']}</a> il {$date} alle {$time}
";
}
}
else
{
echo 'Nessuna Notizia.';
}
?>
Vorrei che il {$row['subject']} avesse dei caratteri tot caratteri, questo perché voglio mostrare gli ultimi 5 topic del mio forum solo che per mostrarli in home devo usare un iFRAME, essendo dentro un box se il titolo è troppo grande le scritte vanno sotto il box.
Spero di essermi fatto capire *-*