1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
|
<?php;
include "5config.php";
if(!@mysql_connect($host,$usrname,$pass)) {
die("Es konnte keine Verbindung zur Datenbank hergestellt werden!");
}
if(!mysql_select_db($db))
{
die("Es Konnte keine Verbindung zur Datenbank hergestellt werden");
}
$sql = "SELECT threadid, topic, lastposttime, lastposter FROM bb".$brdnr."_threads ORDER BY lastposttime DESC LIMIT ".$anz;
$result = mysql_query($sql);
if(!$result) {
die("Konnte den Mysqlstring nicht abschicken");
}
echo "<div align=\"center\"><table cellspacing=\"".$borderwith."\" width=\"".$with."\" bgcolor=\"".$border."\"><tr bgcolor=\"".$hbg."\"><td background=\"".$hbgimg."\" colspan=\"3\"><b>Neue Beiträge im Forum:</b></tr>";
while($row = mysql_fetch_assoc($result))
{
echo "<tr bgcolor=\"".$bg."\"><td background=\"".$bgimg."\" >".date("d.m.Y",$row[lastposttime])."</td><td background=\"".$bgimg."\"> von: ".$row[lastposter]."</td><td width=\"60%\" background=\"".$bgimg."\"> <a href=\"".$board."/thread.php?threadid=".$row[threadid]."\">".$row[topic]."</a></td></tr>";
}
?>
</table></div> |