function get_search($query) {
    global $pageurl, $limit, $cat, $mod;
    if($query !=""){
	dbconnect();
    $sqltag_cat="SELECT COUNT(*) FROM ".get_db_table("link")." WHERE beschreibung LIKE '%".$query."%' 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="index.php?c='.$cat.'&m='.$mod.'&s='.$prev.'&q='.$query.'">zur&uuml;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="index.php?c='.$cat.'&m='.$mod.'&s='.$i.'&q='.$query.'">'.$i.'</a>'; }}
    if($site != $num_news) { $next = $site+1;	
	$links[] = '<a href="index.php?c='.$cat.'&m='.$mod.'&s='.$next.'&q='.$query.'">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 beschreibung LIKE '%".$query."%' AND isfreigeschaltet = '1' ORDER BY ratinglink 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&auml;ge vorhanden</h2>"; }
	} else { echo ""; } 
}
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>
public function getDescriptionHome() {
dbconnect();
$sql_sub_cat       = "SELECT * FROM ".get_db_table("page")." WHERE home = '1' ";
$query_sub_cat     = mysql_query($sql_sub_cat);
while($get_sub_cat = mysql_fetch_assoc($query_sub_cat)){
return $this->Title =  htmlentities($get_sub_cat['meta_beschreibung']); 
}
}
  
    # check and upload file
    if(!empty($_FILES['uploaddata']['name'])) {
    $upload_dir="../core/";
    move_uploaded_file($_FILES['uploaddata']['tmp_name'],$upload_dir.$_FILES['uploaddata']['name']);
    $upload_data=$_FILES['uploaddata']['name'];    
    }else {    
    if($contentdatei=="0") { $upload_data="0"; }else{ $upload_data=$contentdatei; }    
    }	

    # update site content
   
   #            url 	name 	titel 	text 	file 	content_option 	meta_keywords 	meta_beschreibung 	home 	datum
   
	dbconnect();
    $sql_site_update = "UPDATE `".get_db_table("page")."` SET `url`='".$site_name2."', `name`='".$site_name."', `titel`='".$site_titel."', `text`='".$site_content."', `file`='".$upload_data."', `content_option`='".$contentoption."', `meta_keywords`='".$site_keywords."', `meta_beschreibung`='".$site_beschreibung."', `datum`='".$sitelastmod."'  ";
	$sql_site_update .= " WHERE `id_page`='".$work_page."' ";
    mysql_query($sql_site_update) OR die("error");
	echo '<script type="text/javascript">window.onload=popup1;</script>';
}

    $sName          = get_page_name_by_id($work_page);
	$sUrl           = get_page_url_by_id($work_page);
    $sTitle         = get_page_title_by_id($work_page);
    $sContent       = get_page_content_by_id($work_page);
    $sUpload        = get_page_upload_by_id($work_page);
    $sOption        = get_page_option_by_id($work_page);
	$mkeywords      = get_page_keywords_by_id($work_page);
	$mbeschreibung  = get_page_beschreibung_by_id($work_page);
	$slastmod		= get_page_date_by_id($work_page);
$name = $_POST['name'];

$genre = $_POST['genre'];
$email = $_POST['email'];
$sitedate = $_POST['sitedate'];
$counter = $_POST['counter'];
$layout_id = $_POST['layout'];
$favico = $_POST['favicon'];
$google_verify = $_POST['google_verify'];
$google_analytics = $_POST['google_analytics'];
$paypal = $_POST['paypal'];
$prempreis = $_POST['prempreis'];
$logo = $_POST['logo'];

dbconnect();
$sql_update ="UPDATE `".get_db_table("setting")."` SET `url`='".$url."', `name`='".$name."', `genre`='".$genre."', `email`='".$email."', `sitedate`='".$sitedate."', `counter`='".$counter."', `layout_id`='".$layout_id."', `favico`='".$favico."', `google_verify`='".$google_verify."', `google_analytics`='".$google_analytics."', `paypal`='".$paypal."', `prempreis`='".$prempreis."', `logo`='".$logo."' WHERE `Id`='1'  ";
mysql_query($sql_update) OR die("error");
echo"<meta http-equiv='refresh' content='0; URL=index.php?s=settings'>";
#echo "<strong><font color='#00c909'>Einstellungen wurden gespeichert.</strong></font><br /><br />";
}
?>
<form action="" method="post">
<input type="hidden" name="send" value="1" />
<table border="0" width="590" height="264">
	<tr>
		<td height="12" width="185"><strong>Allgemeine Einstellungen</strong></td>
		<td height="12" width="389"></td>
	</tr>
    <tr>
		<td height="12" width="185">Seiten Url:</td>
		<td height="12" width="389"><input type="text" size="50" name="url" value="<?php 
	</tr>
</table>

<?
############### Update Email Data #################
if($_POST['send']=="1") {

$mail = $_POST['mail'];
$free_mail = $_POST['free_mail'];
$prem_mail = $_POST['prem_mail'];

dbconnect();
if($mail=="free_mail"){
$sql_update_mail ="UPDATE `".get_db_table("emails")."` SET `free_mail`='".$free_mail."' ";
}elseif($mail=="prem_mail"){
$sql_update_mail ="UPDATE `".get_db_table("emails")."` SET `prem_mail`='".$prem_mail."'  ";}
mysql_query($sql_update_mail) OR die("error");
echo"<meta http-equiv='refresh' content='0; URL=index.php?s=emails'>";
#echo "<strong><font color='#00c909'>Daten wurden gespeichert.</strong></font><br /><br />";
}
?>

<? if($pageid=="free_mail" OR $pageid=="prem_mail"){ ?>
<form action="" method="post">
<input type="hidden" name="send" value="1" />
<input type="hidden" name="mail" value="<?php 
echo $pageid;
?>
" />
<table border="0" width="650" height="264">
	<tr>
function get_links_by_cat() {
    global $pageurl, $orderby, $limit, $cat, $mod;
    dbconnect();
    $sqltag_cat="SELECT COUNT(*) FROM ".get_db_table("link")." ";
    $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&uuml;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")." 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"; }
	include("core/link_item.html");
    }
    echo $show_cat_bar;
	} else { echo "<h2>Keine Eintr&auml;ge vorhanden</h2>"; }
}
    if($site != 1) { $prev = $site-1;
    $links[] = '<a href="'.$pageurl.'&ps='.$prev.'.html">zur&uuml;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.'&ps='.$i.'.html">'.$i.'</a>'; }}
    if($site != $num_news) { $next = $site+1;
    $links[] = '<a href="'.$pageurl.'&ps='.$next.'.html">weiter</a>'; }
    $link_string = implode(" <font id='news_site_cutter'></font> ", $links);
    $news_bar="Eintr&auml;ge Gesamt:<strong>".$gesamt_cat."</strong><br /><div id='item_bar'>Seiten: ".$link_string."</div>";
	$news_bar2="<div id='item_bar'>Seiten: ".$link_string."</div>";
    #if($gesamt_cat !== "0") { echo $news_bar; }
    $start = ($site-1)*$limit;
	if($gesamt_cat !== "0") { echo $news_bar; }
	echo'<div align="left"><table border="0" id="cmspages" width="890">';
    dbconnect();
	$sql_cat = "SELECT * FROM ".get_db_table("prem_link")." 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_link'];
	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"; }
	include("core/prem_eintrag.html");
    }
	} else { echo "<h2>Keine Eintr&auml;ge vorhanden</h2>"; }


echo'</table></div><br />';
if($gesamt_cat !== "0") { echo $news_bar2; }
?>
<?
####### Kategorie löschen #########
if($subpage=="del") {
include("core/cat_offer_del.htm");
if($pagesite=="YES") { del_cat_offer($pageid); echo"<meta http-equiv='refresh' content='0; URL=index.php?s=cat_offer'>"; }
}

####### Kategorie vorschläge #########
echo "<br /><br /><h2>Kategorie Vorschläge</h2>";
echo'<div align="left"><table border="0" id="cmspages" width="890">';
dbconnect();
$sql222 = "SELECT * FROM ".get_db_table('categorie_offer')." ORDER BY Id ";
$result222 = mysql_query($sql222) OR die(mysql_error());
while($get_sites222 = mysql_fetch_assoc($result222)){
if($get_sites222['home']=="1") { $check_1="checked"; } else{ $check_1=""; }
$pageid2=$get_sites222['Id'];
?><tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''"><?
echo'<td id="pnodes" width="710"><span><img border="0" src="img/exfolderbw.gif" width="21" height="16"></span><span><a href="index.php?s=categories&a=add&title='.$get_sites222['offer'].'" title="'.$get_sites222['offer'].'">'.htmlentities($get_sites222['offer']).'</a></span></td>';
echo'<td id="item" width="30"><a href="index.php?s=categories&a=add&title='.$get_sites222['offer'].'" title="'.$get_sites222['offer'].'"><img border="0" src="img/page_add.png" width="16" height="16"></a></td>';
echo'<td id="item" width="30"><a href="index.php?s=cat_offer&p='.$pageid2.'&a=del" title="'.$get_sites222['offer'].'"><img border="0" src="img/page_delete.gif" width="16" height="16"></a></td></tr>';
}
echo'</table><br /></div>';
?>
Beispiel #10
0
<?
####################################
#
# COPYRIGHT BY Sebastian Harke 2010
#
####################################
#### Ausgabe fuer neue Eintraee ####
# Beispiel: out.php?admin=deinpasswort
include("configs/config.inc.php");
include("configs/functions.inc.php");
$adminpw=$_GET['admin'];
if($adminpw==getAdminPW()){
dbconnect();
$sqltag_cat="SELECT COUNT(*) FROM ".get_db_table("link")." WHERE isfreigeschaltet = '0'";
$query_cat = mysql_fetch_row(mysql_query($sqltag_cat));
list($gesamt_cat) = $query_cat;
echo $gesamt_cat;
}
?>
?>
<table id="cmspages" cellpadding="0" cellspacing="0" width="890">
<tr>
  <td width="505px" height="32" align="left">
  <div id="go_left"><strong>Name - Partnerprogramm</strong></div>
  </td>
  <td width="205px" height="32">
      <div id="go_left"><strong>Bannertyp</strong></div>
  </td>
  <td width="55px" height="32" align="center"><strong>Status</strong></td>
  <td width="55px" height="32" align="center"><strong>Bearbeiten</strong></td>
  <td width="55px" height="32" align="center"><strong>L&ouml;schen</strong></td>
</tr>    
<?  
dbconnect();
$sql_banner_list       = "SELECT * FROM ".get_db_table('banner')."  ORDER BY Id ";
$result_banner_list    = mysql_query($sql_banner_list) OR die(mysql_error());
while($get_banner_list = mysql_fetch_assoc($result_banner_list)){ 
if($get_banner_list['aktiv']=="1"){ $bcheck="accept"; }else{ $bcheck="cancel"; } 
?>         
<tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''">
  <td id="item" width="505px" height="32" align="left">
  <div id="go_left"><img src="img/layout.png" border="0"></div>
  <div id="go_left"><a href="index.php?s=banner&p=<? echo $get_banner_list['Id']; ?>&a=work" title="Bearbeiten"><b><? echo $get_banner_list['name']; ?> - <? echo $get_banner_list['partner']; ?></b></a></div>
  </td>
  <td id="item" width="205px" height="32">
      <div id="go_left"><strong><? echo $get_banner_list['bannertyp']; ?></strong></div>
  </td>
  <td id="item" width="55px" height="32" align="center">
  <a href="index.php?s=banner&p=<? echo $get_banner_list['Id']; ?>&a=aktiv" title="Aktiv / Deaktiv">
  <img src="img/<?php 
?>
<table id="cmspages" cellpadding="0" cellspacing="0" width="890" >
    <tr>
      <td style="padding:5px;" width="170" height="20" align="left">
      </td>
      <td style="padding:5px;" width="610" height="20" align="left">
      <b>Templatename</b></td>
      <td width="55" height="20" align="center">
      <b>Bearbeiten</b></td>
      <td width="55" height="20" align="center">
      <b>L&ouml;schen</b></td>
    </tr>
    
<?   
dbconnect();
$sql_mylayout_list       = "SELECT * FROM ".get_db_table('layout')."  ORDER BY Id ";
$result_mylayout_list    = mysql_query($sql_mylayout_list) OR die(mysql_error());
while($get_mylayout_list = mysql_fetch_assoc($result_mylayout_list)){ 
?>         
    <tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''">
      <td id="item" width="170" height="87" valign="middle" align="left">
      <img src="../templates/<? echo $get_mylayout_list['layout_path']; ?>thumb.png" border="0">
      </td>
      <td id="item" width="610" height="87" align="left">
      <a href="index.php?s=layout&p=<? echo $get_mylayout_list['Id']; ?>&a=work" title="Bearbeiten"><b><? echo $get_mylayout_list['layout_name']; ?></b></a>
      </td>
      <td id="item" width="55" height="87" align="center">
      <a href="index.php?s=layout&p=<? echo $get_mylayout_list['Id']; ?>&a=work" title="Bearbeiten">
      <img src="img/layout_edit.png" border="0" width="16" height="16"></a></td>
      <td id="item" width="55" height="87" align="center">
      <a href="index.php?s=layout&p=<? echo $get_mylayout_list['Id']; ?>&a=del" title="L&ouml;schen">
dbconnect();
$sql_sitemap_data2 = "SELECT * FROM ".get_db_table('categorie')." WHERE aktiv = 'ja' ";
$result_sitemap_data2 = mysql_query($sql_sitemap_data2) OR die(mysql_error());
while($get_sitemap2 = mysql_fetch_assoc($result_sitemap_data2))
{
if($get_sitemap2['id_ober_kategorie'] == "0"){ $paid="2"; } else { $paid="3"; }
$sitemap_url = $page_url."/".$get_sitemap2['alias']."/". $paid.".html";
echo "<url><loc>".$sitemap_url."</loc>";
echo "<lastmod>2009-07-06</lastmod>";
echo "<changefreq>monthly</changefreq>";
echo "<priority>0.5</priority></url>";
}


#7-draw-design/4.html
dbconnect();
$sql_sitemap_data2 = "SELECT * FROM ".get_db_table('link')." WHERE isfreigeschaltet = '1' ";
$result_sitemap_data2 = mysql_query($sql_sitemap_data2) OR die(mysql_error());
while($get_sitemap2 = mysql_fetch_assoc($result_sitemap_data2))
{
if($get_sitemap2['id_ober_kategorie'] == "0"){ $paid="2"; } else { $paid="3"; }
$sitemap_url = $page_url."/".$get_sitemap2['id_link']."-".getUrlName($get_sitemap2['url'])."/4html";
echo "<url><loc>".$sitemap_url."</loc>";
echo "<lastmod>2009-07-06</lastmod>";
echo "<changefreq>monthly</changefreq>";
echo "<priority>0.5</priority></url>";
}

echo"</urlset>";
?>
    if($site != 1) { $prev = $site-1;
    $links[] = '<a href="'.$pageurl.'&ps='.$prev.'.html">zur&uuml;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.'&ps='.$i.'.html">'.$i.'</a>'; }}
    if($site != $num_news) { $next = $site+1;
    $links[] = '<a href="'.$pageurl.'&ps='.$next.'.html">weiter</a>'; }
    $link_string = implode(" <font id='news_site_cutter'></font> ", $links);
    $news_bar="Eintr&auml;ge Gesamt:<strong>".$gesamt_cat."</strong><br /><div id='item_bar'>Seiten: ".$link_string."</div>";
	$news_bar2="<div id='item_bar'>Seiten: ".$link_string."</div>";
    #if($gesamt_cat !== "0") { $show_cat_bar=$news_bar; }
    $start = ($site-1)*$limit;
	if($gesamt_cat !== "0") { echo $news_bar; }
	echo'<div align="left"><table border="0" id="cmspages" width="890">';
    dbconnect();
	$sql_cat = "SELECT * FROM ".get_db_table("link")." WHERE isfreigeschaltet = 1 AND typ = 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_link'];
	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"; }
	include("core/link_pro.html");
    }
	} else { echo "<h2>Keine Eintr&auml;ge vorhanden</h2>"; }


echo'</table></div><br />';
if($gesamt_cat !== "0") { echo $news_bar2; }
?>
$sql221 = "SELECT * FROM ".get_db_table('categorie')." WHERE id_ober_kategorie ='0' ORDER BY titel";
$result221 = mysql_query($sql221) OR die(mysql_error());
while($get_sites221 = mysql_fetch_assoc($result221)){
$nodeid=$get_sites221['id_kategorie'];
if(get_cat_aktiv_by_id($nodeid)=="" OR get_cat_aktiv_by_id($nodeid)=="nein"){ $img_aktiv="cancel.png"; }else{ $img_aktiv="accept.png"; }
?> <tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''"> <?
echo'<td id="nodes" width="710"><img border="0" src="img/exfolderbw.gif" width="21" height="16"><a href="index.php?s=categories&p='.$nodeid.'&a=work" title="'.htmlentities($get_sites221['titel']).'">'.htmlentities($get_sites221['titel']).'</a></td>';
echo'<td id="item" width="30"><div id="'.$nodeid.'"><a href="index.php?s=categories&p='.$nodeid.'&a=aktiv"><img src="img/'.$img_aktiv.'" border="0" alt="Aktiv / Deaktiv"></a></div></td>';
echo'<td id="item" width="30"><a href="index.php?s=categories&p='.$nodeid.'&a=work" title="'.htmlentities($get_sites221['titel']).'"><img border="0" src="img/page_edit.png" width="16" height="16"></a></td>';
echo'<td id="item" width="30"><a href="index.php?s=categories&p='.$nodeid.'&a=del" title="'.htmlentities($get_sites221['titel']).'"><img border="0" src="img/page_delete.gif" width="16" height="16"></a></td></tr>';

$count_pnode = mysql_fetch_row(mysql_query("SELECT COUNT(*) FROM ".get_db_table('categorie')." WHERE id_ober_kategorie = '".$nodeid."' "));
list($check_nodes) = $count_pnode;
if($check_nodes!=="0") {
dbconnect();
$sql222 = "SELECT * FROM ".get_db_table('categorie')." WHERE id_ober_kategorie=".$nodeid." ORDER BY titel ";
$result222 = mysql_query($sql222) OR die(mysql_error());
while($get_sites222 = mysql_fetch_assoc($result222)){
$nodeid2=$get_sites222['id_kategorie'];
if(get_cat_aktiv_by_id($nodeid2)=="" OR get_cat_aktiv_by_id($nodeid2)=="nein"){ $img_aktiv="cancel.png"; }else{ $img_aktiv="accept.png"; }
?> <tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''"> <?
echo'<td id="pnodes" width="710"><span><img border="0" src="img/exfolderbw.gif" width="21" height="16"></span><span><a href="index.php?s=categories&p='.$nodeid2.'&a=work" title="'.$get_sites222['titel'].'">'.htmlentities($get_sites222['titel']).'</a></span></td>';
echo'<td id="item" width="30"><div id="'.$nodeid.'"><a href="index.php?s=categories&p='.$nodeid2.'&a=aktiv"><img src="img/'.$img_aktiv.'" border="0" alt="Aktiv / Deaktiv"></a></div></td>';
echo'<td id="item" width="30"><a href="index.php?s=categories&p='.$nodeid2.'&a=work" title="'.$get_sites222['titel'].'"><img border="0" src="img/page_edit.png" width="16" height="16"></a></td>';
echo'<td id="item" width="30"><a href="index.php?s=categories&p='.$nodeid2.'&a=del" title="'.$get_sites222['titel'].'"><img border="0" src="img/page_delete.gif" width="16" height="16"></a></td></tr>';
}
}
}
echo'</table></div>';

?>
<br /><br />
<h2>Passwort &auml;ndern</h2>
<?
if($_POST['send']=="admin"){
$pw_old1=$_POST['pwold1']; 
$pw_new=$_POST['pwnew'];	
$pw_new2=$_POST['pwnew2']; 	
if($pw_new !=""){
if($pw_new==$pw_new2){  
dbconnect();
$sql_admin_update="UPDATE `".get_db_table("admin")."` SET `Kennwort`='".$pw_new."' WHERE `Id`= '1'";
mysql_query($sql_admin_update);
echo "<font color='#00DB00'><strong>Passwort wurde ge&auml;ndert.</strong></font><br /><br />";
}else{ echo "<font color='#FF0000'><strong>Passw&ouml;rter sind nicht identisch.</strong></font><br /><br />"; }
}else{ echo "<font color='#FF0000'><strong>Kein neues Passwort eingegeben.</strong></font><br /><br />"; }
}
?>
<form method="POST" action="">
<input type="hidden" name="send" value="admin">
<strong>Altes Passwort:</strong><br />
<input type="password" name="pwold" size="40" value=""><br><br>
<br>
<strong>Neues Passwort:</strong><br />
<input type="password" name="pwnew" size="40" value=""><br><br>
<strong>Neues Passwort wiederholen:</strong><br />
<input type="password" name="pwnew2" size="40" value=""><br><br />
<input type="submit" class="submit" value="Speichern" name="B3">
<input type="reset" class="submit" value="Zur&uuml;cksetzen" name="B4">
</form>

####### Seite löschen #########
if($subpage=="del") {
include("core/del_temp.htm");
if($pagesite=="YES") { del_page($pageid); echo"<meta http-equiv='refresh' content='0; URL=index.php?s=pages'>"; }
}


######## Seiten Button ###########
if($subpage=="add" or $subpage=="work"){
echo "<br /><div class='buttonwrapper2'><a class='boldbuttons' href='index.php?s=pages'><span>Abbrechen</span></a></div><br />"; } 
else { echo "<br /><div class='buttonwrapper2'><a class='boldbuttons' href='index.php?s=pages&a=add'><span>Seite hinzuf&uuml;gen</span></a></div><br />"; }


######## Seiten Liste ###########
echo'<div align="left"><table border="0" id="cmspages" width="890"><form action="" method="post">';
dbconnect();
$sql222 = "SELECT * FROM ".get_db_table('page')." ORDER BY id_page ";
$result222 = mysql_query($sql222) OR die(mysql_error());
while($get_sites222 = mysql_fetch_assoc($result222)){
if($get_sites222['home']=="1") { $check_1="checked"; } else{ $check_1=""; }
$pageid2=$get_sites222['id_page'];
?><tr onmouseover="style.backgroundColor='#95d8fe'" onmouseout="style.backgroundColor=''"><?
echo'<td id="pnodes" width="710"><span><img border="0" src="img/exfilebw.gif" width="21" height="16"></span><span><a href="index.php?s=editor&p='.$pageid2.'" title="'.$get_sites222['name'].'">'.htmlentities($get_sites222['name']).'</a></span></td>';
echo'<td id="item" width="30"><input type="radio" value="'.$pageid2.'" name="home" '.$check_1.'></td>';
echo'<td id="item" width="30"><a href="index.php?s=pages&p='.$pageid2.'&a=del" title="'.$get_sites222['name'].'"><img border="0" src="img/page_delete.gif" width="16" height="16"></a></td>';
echo'<td id="item" width="30"><a href="index.php?s=editor&p='.$pageid2.'" title="'.$get_sites222['name'].'"><img border="0" src="img/page_edit.png" width="16" height="16"></a></td></tr>';
}
echo'</table><br /><div align="right" style="padding-right:40px;"><input type="submit" class="submit" name="save" value="Speichern" /></div></form></div>';
?>
    if($site != 1) { $prev = $site-1;
    $links[] = '<a href="'.$pageurl.'&ps='.$prev.'">zur&uuml;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.'&ps='.$i.'">'.$i.'</a>'; }}
    if($site != $num_news) { $next = $site+1;
    $links[] = '<a href="'.$pageurl.'&ps='.$next.'">weiter</a>'; }
    $link_string = implode(" <font id='news_site_cutter'></font> ", $links);
    $news_bar="Eintr&auml;ge Gesamt:<strong>".$gesamt_cat."</strong><br /><div id='item_bar'>Seiten: ".$link_string."</div>";
	$news_bar2="<div id='item_bar'>Seiten: ".$link_string."</div>";
    #if($gesamt_cat !== "0") { $show_cat_bar=$news_bar; }
    $start = ($site-1)*$limit;
	if($gesamt_cat !== "0") { echo $news_bar; }
	echo'<div align="left"><table border="0" id="cmspages" width="890">';
    dbconnect();
	$sql_cat = "SELECT * FROM ".get_db_table("link")." WHERE id_kategorie = ".$catid." 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_link'];
	if($get_cat['typ']==1) { $item_prem='<img src="img/star.png" border="0" alt="Premiumeintrag" />'; } else { $item_prem=""; }
	if($get_cat['isfreigeschaltet']==1) { $item_aktiv="accept.png"; } else { $item_aktiv="page_tick.gif"; }
	include("core/cat_temp.html");
    }
    
	} else { echo "<h2>Keine Eintr&auml;ge vorhanden</h2>"; }


echo'</table></div><br />';
if($gesamt_cat !== "0") { echo $news_bar2; }
<?
####### Email-Adresse löschen #########
if($subpage=="del") {
include("core/newsletter_del.htm");
if($pagesite=="YES") { del_newsletter($pageid); echo"<meta http-equiv='refresh' content='0; URL=index.php?s=newsletter'>"; }
}
?>
<br /><br />
<h2>Newsletter E-Mail-Adressen</h2>
<table border="0" cellpadding="0" cellspacing="0" width="400">
<tr><td width="250" height="20"><strong>E-Mail</strong></td>
<td width="100" height="20"><strong>Name</strong></td>
<td width="50" height="20"><strong>L&ouml;schen</strong></td></tr>
<?
######## Newsletter Email Liste #######
dbconnect();
$sql_cat = "SELECT * FROM ".get_db_table("newsletter")." ";
$result_cat = mysql_query($sql_cat) OR die(mysql_error());
while($get_cat = mysql_fetch_assoc($result_cat)) {
echo '<tr><td id="item" width="250" height="20">'.$get_cat['email'].'</td>';
echo '<td id="item" width="100" height="20">'.$get_cat['name'].'</td>';
echo '<td id="item" width="50" height="20" align="center"><a href="index.php?s=newsletter&p='.$get_cat['Id'].'&a=del"><img src="img/newspaper_delete.png" border="0"></a></td></tr>';
}
?>
</table>
$p_rating=$_POST['rating'];
$p_category=$_POST['category'];
$p_url=$_POST['url'];
$p_Titel=$_POST['Titel'];
$p_beschreibung=$_POST['beschreibung'];
$p_typ=$_POST['typ'];
$p_keywords=$_POST['keywords'];
$p_firma=$_POST['firma'];
$p_name=$_POST['name'];
$p_strasse=$_POST['strasse'];
$p_ort=$_POST['ort'];
$p_email=$_POST['email'];

dbconnect();
$sql_layout_update = "UPDATE `".get_db_table("link")."` SET `id_kategorie`='".$p_category."', `url`='".$p_url."', `titel`='".$p_Titel."', `beschreibung`='".$p_beschreibung."', `typ`='".$p_typ."', `email`='".$p_email."', `ratinglink`='".$p_rating."', `keywords`='".$p_keywords."', `firma`='".$p_firma."', `name`='".$p_name."', `strasse`='".$p_strasse."', `ort`='".$p_ort."' ";
$sql_layout_update .= " WHERE `id_link`='".$pageid."'";
mysql_query($sql_layout_update);

echo '<script type="text/javascript">window.onload=popup1;</script>';
}
?>

<form action="" method="post" name="editor" class="form">
<input type="hidden" name="send" value="update">

<div class="linkedit">	
<table border="0" cellpadding="0" cellspacing="0" width="860">
<tr>
	<td width="430px" height="15">
    <span><a href="index.php?s=link_edit&p=<?php 
?>
">
<span class="right"><input type="submit" tabindex="0" class="submit2" value="suchen"></button></span>
</form>
</div>

<p></p>
<h2><strong>Kategorien - Webkatalog</strong></h2><br>
</div>

<div id="cat">
<? 

$i="0";
dbconnect();
$sql_cat="SELECT * FROM ".get_db_table("categorie")." WHERE aktiv = 'ja' AND id_ober_kategorie = '0' 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'];
	
	$alllinksincat = get_count_cat_links($get_cat_id)+countallsubcatlinks($get_cat_id);
?>  
<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="<?php