Esempio n. 1
0
<table>
<?php 
foreach ($this->conteudos as $conteudo) {
    if ($conteudo) {
        echo "<tr><td><a href='?action=editaconteudo&id=" . $conteudo->id . "'>" . $conteudo->titulo . "</td><td>" . $conteudo->html . "</td></tr>\n";
    }
}
?>
</table>

<br><br>
<br><br>

<?php 
// Paging links
$todosconteudos = new Conteudo();
$todosconteudos->all(1, 'titulo');
$tr = $todosconteudos->getNumRows();
//tr - total of registers
paging($tr, $rpp, $pg);
for ($x = 0; $x < $nf; $x++) {
    if ($sgbd == 'my') {
        $fn = mysql_field_name($res, $x);
    } elseif ($sgbd == 'pg') {
        $fn = pg_field_name($res, $x);
    }
    $flds .= "<option value='{$fn}'>" . ucfirst($fn) . "</option>";
}
?>