esta es la situacion
Código PHP:
$myts =& MyTextSanitizer::getInstance();
$sql = "SELECT storyid, title, published, expired, topicid, counter FROM ".$datosDB->prefix("stories")." WHERE published < ".time()." AND published > 0 AND (expired = 0 OR expired > ".time().") ORDER BY created DESC";
$result = $datosDB->query($sql,5,0);
while ( $myrow = $datosDB->fetchArray($result) ) {
$noticias = array();
$title = $myts->makeTboxData4Show($myrow["title"]);
if ( !DATOS_USE_MULTIBYTES ) {
if (strlen($myrow['title']) >= 100) {
$title = $myts->makeTboxData4Show(substr($myrow['title'],0,(100 -1)))."...";
}
}
$datosTpl-> append('noticias', array(
'title' => $title,
'id' => $myrow['storyid'],
'date' => formatTimestamp($myrow['published'],"s")
));
}
sin embargo quiero que se puedan ver por topic ,¿como se hace?
Osea que solo se vea supongamos las noticias del topic 1
Actualmente usa este codigo html
Código HTML:
<{foreach item=i from=$noticias}> <a href="<{$datos_url}>/article.php?storyid=<{$i.id}>"> <{$i.title}></a> (<{$i.date}>)<br> <{/foreach}>
noticia 7 (2006/10/28)
noticia 6 (2006/10/28)
noticia 5 (2006/10/28)
noticia 4 (2006/10/28)
noticia 3(2006/10/28)
Nota, se usa smarty.
Agradezco si alguien puede ayudarme, pues entre en un lapsus tremendus , y no salgo de ahi.