function get_cat($cat_id) { global $pageurl, $orderby, $limit, $cat, $mod; dbconnect(); $sqltag_cat="SELECT COUNT(*) FROM ".get_db_table("link")." WHERE id_kategorie = '".get_alias_to_cat_id($cat_id)."' AND isfreigeschaltet = '1'"; $query_cat = mysql_fetch_row(mysql_query($sqltag_cat)); list($gesamt_cat) = $query_cat; if($gesamt_cat!="0") { $num_news = ceil($gesamt_cat/$limit); if(empty($_GET['s'])) { $site = 1; } elseif($_GET['s'] <= 0 || $_GET['s'] > $num_news) { $site = 1; } else { $site = $_GET['s']; } $links = array(); if($site != 1) { $prev = $site-1; $links[] = '<a href="'.$pageurl.'/'.$prev.'.html">zurück</a>'; } for($i=1;$i<=$num_news;$i++) { if($i == $site) { $links[] = '<a class="aktiv_item"><b>'.$i.'</b></a>'; } else { $links[] = '<a class="itemlink" href="'.$pageurl.'/'.$i.'.html">'.$i.'</a>'; }} if($site != $num_news) { $next = $site+1; $links[] = '<a href="'.$pageurl.'/'.$next.'.html">weiter</a>'; } $link_string = implode(" <font id='news_site_cutter'></font> ", $links); $news_bar="<div id='item_bar'>Seiten: ".$link_string."</div>"; if($gesamt_cat !== "0") { $show_cat_bar=$news_bar; } $start = ($site-1)*$limit; dbconnect(); $sql_cat = "SELECT * FROM ".get_db_table("link")." WHERE id_kategorie = '".get_alias_to_cat_id($cat_id)."' AND isfreigeschaltet = '1' ORDER BY ".$orderby." DESC LIMIT ".$start.",".$limit.""; $result_cat = mysql_query($sql_cat) OR die(mysql_error()); while($get_cat = mysql_fetch_assoc($result_cat)) { $get_seite_id=$get_cat['id_kategorie']; if($get_cat['typ']==1) { $item_look="seite_item_star"; $item_look_bottom="seite_item_bottom_star"; } else { $item_look="seite_item"; $item_look_bottom="seite_item_bottom"; } $temppath="templates/".get_aktiv_layout_data("layout_path")."content_temp/cat_item.html"; include($temppath); } echo $show_cat_bar; } else { echo "<h2>Keine Einträge vorhanden</h2>"; } }
images/sign.gif" border="0" /></div> <div id="headline_right"><h1>Unterkategorien von: <?php echo $p_title; ?> </h1></div> </div> <br clear="left" /> </div> <div id="cat"> <? $i="0"; dbconnect(); $sql_cat="SELECT * FROM ".get_db_table("categorie")." WHERE aktiv = 'ja' AND id_ober_kategorie = '".get_alias_to_cat_id($cat)."' ORDER BY titel ASC "; $query_cat=mysql_query($sql_cat); while($get_cat = mysql_fetch_assoc($query_cat)){ $zahl = $i++; if ($zahl % 2 != 0) { $tab_br="<br clear='left' />"; } else { $tab_br=""; } $get_cat_id=$get_cat['id_kategorie']; ?> <div id="cat_item"> <div id="cat_item_left"><img src="templates/<?php echo get_aktiv_layout_data(layout_path); ?> images/dicpic.jpg"></div> <div id="cat_item_right"> <a href="<? echo $page_url."/".$get_cat['alias']; ?>/3.html" class="link"><strong><? echo $get_cat['titel']; ?></strong></a> (<? echo get_count_cat_links($get_cat_id); ?>)<br /> </div> </div>
<? #################################### # # COPYRIGHT BY Sebastian Harke 2010 # #################################### if($_GET['m']==1){ # Seite $bc_link = "<a href='".$page_url."' title='Startseite'>Startseite</a> > ".$gp->getName($cat).""; }elseif($_GET['m']==2){ # Kategorien $bc_link = "<a href='".$page_url."' title='Startseite'>Startseite</a> > ".get_alias_to_cat_title($cat).""; }elseif($_GET['m']==3){ # Sub Kategorien $bc_link = "<a href='".$page_url."' title='Startseite'>Startseite</a> > <a href='".getCatDownAlias(get_alias_to_cat_id($cat))."/2.html'>".getCatDownName(get_alias_to_cat_id($cat))."</a> > ".get_alias_to_cat_title($cat)." "; }elseif($_GET['m']==4){ # Details $bc_link = "<a href='".$page_url."' title='Startseite'>Startseite</a> > Details von: ".getItemLinkById(getUrlBack($cat)).""; }else{ # Startseite $bc_link = $gp->getNameHome(); } ?>