예제 #1
0
</form>

<?php 
$q = mysql_query("SELECT id_n FROM noticia ORDER BY id_n DESC");
if (mysql_num_rows($q) > 0) {
    while ($row = mysql_fetch_array($q)) {
        $noticia = new Noticia($row['id_n']);
        ?>
			
			<div class="noticia" id="<?php 
        echo $noticia->getId();
        ?>
">
				<img src="img/delete.png" class="eliminarNoti tool"><div class="tooltip">Eliminar noticia</div>
				<div class="fotoNoticia" style="background-image:url(<?php 
        echo substr($noticia->getFoto(), 3);
        ?>
);background-repeat:no-repeat;"></div>
				<div class="contNoticia">
					<div class="tituloNoticia"><?php 
        echo $noticia->getTitulo();
        ?>
</div>
					<div class="descNoticia"><textarea disabled="disabled"><?php 
        echo $noticia->getDescripcion();
        ?>
</textarea></div>
				</div>
			</div>
<?php 
    }