<define-tag th endtag=required><*th>%body<*/th></define-tag>
-#<table border=0 cellspacing=3 bgcolor="#f7ba2e">
-<table width=100% border=0 cellspacing=0 cellpadding=1>
-<tr bgcolor=#<colh>><th>Nr.</th><th>Autor</th><th>Titel</th><th>Datum</th></tr>
+<table class="border smallfont" width=100% border=0 cellspacing=0 cellpadding=1>
+<tr class=head><th>Nr.</th><th>Autor</th><th>Titel</th><th>Datum</th></tr>
<?
$dbh = pg_pconnect ("<dbhost>", "<dbport>", "<dbname>")
$query = "SELECT id,subject,author,releasedate,deleted FROM news ORDER BY releasedate DESC,insertd DESC";
$sth = pg_exec ($dbh, $query) or die("Datenbank-Abfrage!");
- $color = "<cold>";
+ $color = 0;
for ($nr=0; $nr < pg_NumRows ($sth); $nr++) {
$row = pg_fetch_array ($sth, $nr);
$date = explode (" ", $row['releasedate']);
$date = explode ("-", $date[0]);
$date = sprintf ("%d.%d.%d", $date[2], $date[1], $date[0]);
- $color = $color == "<cold>"?"<coln>":"<cold>";
- printf ("<tr bgcolor=\"#%s\"><td>%d</td>", $color, $nr+1);
+ printf ("<tr class=\"t%d\"><td>%d</td>", $color, $nr+1);
if ($row['deleted'] == 1) {
$del = " (del)";
} else {
}
printf ("<td>%s</td><td><a href=\"edit.php?id=%d\">%s</a>%s</td><td align=\"right\">%s</td></td></tr>",
$row['author'], $row['id'], $row['subject'], $del, $date);
+ $color = !$color;
}
?>
</table>
+<p> </p>
+
</page>
# Local variables: