"; } } if (!IsSet($news_begin)) { $news_begin=0; } if (!IsSet($DISPLAY_NEWS)) { $DISPLAY_NEWS = 5; } if (($news_begin-$DISPLAY_NEWS) >= 0 ) { echo "

Die vorherigen $DISPLAY_NEWS News anzeigen...
"; } $SQL = "SELECT * FROM `News` ORDER BY 'ID' DESC LIMIT $news_begin,$DISPLAY_NEWS"; $Erg = mysql_query($SQL, $con); // anzahl zeilen $news_rows = mysql_num_rows($Erg); for ($n = 0 ; $n < $news_rows ; $n++) { echo "

".mysql_result($Erg, $n, "Betreff")."
\n"; echo "   ".mysql_result($Erg, $n, "Datum").", "; echo UID2Nick(mysql_result($Erg, $n, "UID")).""; // avatar anzeigen? echo DisplayAvatar (mysql_result($Erg, $n, "UID")); echo "

\n"; echo "

".nl2br(mysql_result($Erg, $n, "Text"))."

\n"; $RefID=mysql_result($Erg, $n, "ID"); $countSQL="SELECT COUNT(*) from news_comments where Refid = '$RefID'"; $countErg = mysql_query($countSQL, $con); $countcom = mysql_result($countErg, 0, "COUNT(*)"); echo "

$countcom comments

\n\n"; } echo "Die nächsten $DISPLAY_NEWS News anzeigen..."; ?>

Neue News erstellen:

 
">
Betreff:
Text:
Treffen: