acá les dejo el while
Código PHP:
while($noticias = pg_fetch_array($_pagi_result)){
$time = strftime("%A %d de %B del %Y a las %H:%m:%S", $noticias[fecha]); // conversion de fecha
echo <<<HTML
<div id="noticias">
<h2>$noticias[titulo]</h2>
<em>Agregado el $time en $noticias[categoria]</em>
<p>$noticias[contenido]</p>
<em><a href="$PHP_SELF?action=noticiacompleta&id=$noticias[id]">Te falta leer lo mejor de $noticias[titulo] >></a></em>
</div>
HTML;
}