|
$curtime = time();
$anzperpage = 5;
$refmuster = "$SELF?kat=$menue_ID&";
$trennlinie = $groesse[1]-$groesse[7]-$groesse[9]-'30px'; //Trennlinienbreite
$sql = "SELECT c.content_ID FROM content2menue c2m, tab_content c ".($anz_u2c>0 ?", user2content u2c ":"")
."WHERE c2m.menue_ID = $menue_ID
AND c2m.content_start <= $curtime
AND (c2m.content_end >= $curtime OR c2m.content_end = 0)
AND c.content_ID = c2m.content_ID
AND c.content_online ='1'
AND (c.content_zugriff <= $user_rechte".($anz_u2c>0 ?" OR (u2c.content_ID = c.content_ID AND u2c.user_ID = $user_ID)":"").")
GROUP BY c.content_ID
ORDER BY c2m.content_position"
.$limit;
$con = mysql_query($sql,$link);
$gesamt = mysql_num_rows($con);
if ($limit=="")
{
$begin = $HTTP_GET_VARS['begin'];
if (!isset($begin)) {$begin = 0;}
$limit=" LIMIT $begin,$anzperpage";
$ref = pagerefs($anzperpage,$gesamt,$begin,$refmuster);
$sql = $sql.$limit;
$con = mysql_query($sql,$link);
}
$anz_row = mysql_num_rows($con);
$showkurz = true;
$zaehler = 0;
echo "";
while ($row = mysql_fetch_array($con))
{
$zaehler++;
echo "";
$content_ID=$row["content_ID"];
$content_layout_pfad = get_content_layout($content_ID,$menue_ID,$link);
include("$content_layout_pfad");
$angezeigt = $angezeigt.($angezeigt!="" ? ",":"").$content_ID;
echo " | ";
if ($zaehler < $anz_row) echo "
| ";
}
echo " "
.($ref!="" ? "$ref ":"");
?>
|
|