0)); if($_GET[action]=='edit' or $_POST[action]=='editannc'){ $annc=mysql_fetch_array(mysql_query("SELECT * FROM announcements WHERE id=$id")); if($annc[forum]>0 && $ismod) $canpost=true; } $smilies=readsmilies(); if(!$action){ loadtlayout(); $ppp=($log?$loguser[postsperpage]:20); $min=$ppp*$page; $anncs=mysql_query("SELECT a.*,u.*,a.title atitle,u.id uid FROM announcements a,users u WHERE forum=$f AND a.user=u.id ORDER BY a.id DESC LIMIT $min,$ppp"); $annctotal=@mysql_result(mysql_query("SELECT count(*) FROM announcements WHERE forum=$f"),0,0); $pagelinks=$smallfont.'Pages:'; for($i=0;$i<($annctotal/$ppp);$i++){ if($i==$page) $pagelinks.=' '.($i+1); else $pagelinks.=" ".($i+1).''; } $annclist="$tccellh width=150>User$tccellh colspan=2>Announcement