kann mir eine da helfen^^
hier ist die telenumber.php
<?php # Copyright by: Manuel Staechele # Support: www.ilch.de # Mod by: Siggi defined ('main') or die ( 'no direct access' ); $title = $allgAr['title'].' :: Telefonnummern'; $hmenu = 'Telefonnummern'; $design = new design ( $title , $hmenu ); $design->header(); switch($menu->get(1)) { case 1 : $tpl = new tpl ( 'telenumber.htm' ); $ar = array ('uname' => $_SESSION['authname']); $tpl->set_ar_out($ar,3); break; case 2 : $name = escape($_POST['name'], 'string'); $nummer = escape($_POST['nummer'], 'string'); $wohnort = escape($_POST['wohnort'], 'string'); db_query("INSERT INTO prefix_telenumber (`name`,`nummer`,`wohnort`,`userid`) VALUES ('".$name."', '".$nummer."', '".$wohnort."', '".$_SESSION['authid']."')"); wd('index.php?telenumber',$lang['insertsuccessful']); break; default : # loeschen if ($menu->getA(1) == 'd' AND is_numeric($menu->getE(1))) { $id = escape($menu->getE(1), 'integer'); $r = db_fetch_assoc(db_query("SELECT * FROM prefix_telenumber WHERE id = " . $id)); if (has_right(-9) OR $r['userid'] == $_SESSION['authid']) { db_query("DELETE FROM prefix_telenumber WHERE id = ".$menu->getE(1)); } } $tpl = new tpl ( 'telenumber.htm' ); if (loggedin()) { $eintrag = '<a href="index.php?telenumber-1">'.$lang['insert'] .'</a>'; }else{ $eintrag = ''; } $eintraege = @db_result(db_query("SELECT count(*) FROM prefix_telenumber"),0); $ar = array ('eintraege' => $eintraege, 'eintrag' => $eintrag, 'uname' => $_SESSION['authname']); $tpl->set_ar_out($ar,0); $class = ''; $erg = db_query('SELECT * FROM prefix_telenumber ORDER BY id ASC'); while ($row = db_fetch_assoc($erg)) { $class = ($class == 'Cmite' ? 'Cnorm' : 'Cmite' ); $row['class'] = $class; if (has_right(-9) OR $row['userid'] == $_SESSION['authid']) { $row['del'] = '<a href="index.php?telenumber-d'.$row['id'].'"><img src="include/images/icons/del.gif" border="0" title="'.$lang['delete'].'" alt="'.$lang['delete'].'" /></a>'; }else{ $row['del'] = ''; } $tpl->set_ar_out($row,1); } $tpl->out(2); } $design->footer(); ?>
verwendete ilch Version: 1.1 O
betroffene Homepage: externer Link
Zuletzt modifiziert von RazorHD am 07.12.2013 - 23:06:40