/**
  * Zeigt die Gallery an, genauer einen Teil der Bilder zu der gehörenden Gallery.
  * Eine Gallery kann in mehrere Seiten unterteilt sein, je nach der Anzahl der Bilder.
  * Eine Gallery kann eine übergeordnete Kategorie haben, jedoch keine übergeordnete Gallery.
  * @global int gallery_pics_x Number of pictures in x
  * @global int $gallery_pics_y Number of pictures in y
  * @param int $gal_ID Gallery-ID
  */
 private function _showGallery($gal_ID)
 {
     $this->_tplfile = 'gallery_album.tpl';
     /* Anzeige-Config-Daten auslesen */
     include_once USER_DIR . 'config/user-config.inc.php';
     /*Aktuelle Seite ermitteln */
     $page = Page::get_current_page($this->_gpc['GET']);
     //Ein paar Daten berechnen
     $bildproseite = (int) (GALLERY_PICS_X * GALLERY_PICS_Y);
     $start = (int) (($page - 1) * $bildproseite);
     //Anzahl Eintraege
     $this->_mysql->query("SELECT * FROM gallery_eintraege WHERE fid_album = '{$gal_ID}'");
     $number = $this->_mysql->num_rows();
     //Eintraege und Albenname abrufen
     $this->_mysql->query("SELECT `gallery_eintraege`.`fid_bild` as 'img_ID', `gallery_alben`.`name`, `gallery_alben`.`ref_ID`\n\t\t\t\t\t\t\tFROM `gallery_eintraege`,`gallery_alben`\n\t\t\t\t\t\t\tWHERE `gallery_alben`.`ID` = '{$gal_ID}' AND `gallery_eintraege`.`fid_album` = '{$gal_ID}'\n\t\t\t\t\t\t\tORDER BY `gallery_eintraege`.`sequence`\n\t\t\t\t\t\t\tLIMIT {$start},{$bildproseite}");
     $this->_mysql->saverecords('assoc');
     $gallery_imgs = $this->_mysql->get_records();
     $gallery_name = $gallery_imgs[0]['name'];
     $cat_ID = $gallery_imgs[0]['ref_ID'];
     $pages_array = Page::get_static_pagesnav_array($number, $bildproseite, $this->_gpc['GET']);
     $root = $this->_getRoot($cat_ID, true);
     //Smarty-Variablen belegen
     $this->_smarty->assign('root', $root);
     $this->_smarty->assign("pages", $pages_array);
     $this->_smarty->assign("gallery", $gallery_imgs);
     $this->_smarty->assign(array('thispage' => $page, 'number' => $number, 'gal_ID' => $gal_ID, 'top_ID' => $root[count($root) - 1]['ID'], 'gallery_name' => $gallery_name, 'breakline' => GALLERY_PICS_X));
 }
    private function _view()
    {
        $this->_tpl_file = "members.tpl";
        $members = array();
        $this->_mysql->query('Select members_ID, members_name, members_spitzname, 
		DATE_FORMAT(`members_birthday`, \'%W, %e.%m.%Y\') as members_birthday, members_song, members_hobby, 
		members_job, members_motto, members_FIDimage FROM `members` 
		ORDER BY `members`.`members_birthday` ASC Limit 0,30');
        $this->_mysql->saverecords('assoc');
        $members = $this->_mysql->get_records();
        $this->_smarty->assign('members', $members);
    }
 /**
  * Zeigt die einzelnen Contents an.
  *
  * @param int $number Anzahl Einträge pro Seite
  */
 private function _view($number = 15)
 {
     $this->_tplfile = 'content.tpl';
     $this->_mysql->query("SELECT COUNT(*) as 'count' FROM `content`");
     $count = $this->_mysql->fetcharray('assoc');
     $count = $count['count'];
     $page = Page::get_current_page($this->_gpc['GET']);
     $pages_nav = Page::get_static_pagesnav_array($count, $number, $this->_gpc['GET']);
     $start = ($page - 1) * $number;
     $this->_mysql->query("SELECT `content_ID` , `content_title` , `content_text` ,\n\t\tDATE_FORMAT(`content_time`, '{$this->_timeformat}') as 'content_time', `content_archiv`\n\t\tFROM `content` \n\t\tORDER BY `content_archiv` ASC, `content_time`,`content_changed_time` LIMIT {$start}, {$number}");
     $this->_mysql->saverecords('assoc');
     $content_data = $this->_mysql->get_records();
     $this->_smarty->assign('contents', $content_data);
     $this->_smarty->assign('pages', $pages_nav);
 }
 /**
  * Zeigt die einzelnen Contents an.
  *
  * @param int $number Anzahl Einträge pro Seite
  */
 private function _view($number = 20)
 {
     $this->_tplfile = 'module.tpl';
     if ($this->_isformsend()) {
         $this->_updmods();
     }
     $this->_mysql->query("SELECT COUNT(*) as 'count' FROM `modules`");
     $count = $this->_mysql->fetcharray('assoc');
     $count = $count['count'];
     $page = Page::get_current_page($this->_gpc['GET']);
     $pages_nav = Page::get_static_pagesnav_array($count, $number, $this->_gpc['GET']);
     $start = ($page - 1) * $number;
     $this->_mysql->query("SELECT `modules_ID`, `modules_name`, `modules_file`, `modules_template_support`, `modules_mail_support`, `modules_status` FROM `modules` LIMIT {$start}, {$number}");
     $this->_mysql->saverecords('assoc');
     $modules_data = $this->_mysql->get_records();
     $this->_smarty->assign('modules', $modules_data);
     $this->_smarty->assign('pages', $pages_nav);
     $this->_smarty->assign('info', $this->_getinfo(true));
 }
 /**
  * Kontrolliert, ob die angegebenen Spalten vorhanden sind
  * @see _get_tabledata
  *
  * @param array $table_data
  * @return boolean
  */
 private function _check_mailtable()
 {
     $table_infos = array();
     $colums_names = array();
     $columns_search = array($this->mail_tbl['column_ID'], $this->mail_tbl['column_name'], $this->mail_tbl['column_email']);
     $this->_mysql->query("SHOW COLUMNS FROM `{$this->mail_tbl['table']}`");
     $this->_mysql->saverecords('assoc');
     $table_infos = $this->_mysql->get_records();
     //Zuschneiden von $table_infos (komplexes Array) in ein einfaches Array
     foreach ($table_infos as $key => $value) {
         $colums_names[$key] = $table_infos[$key]['Field'];
     }
     //Sind die angebenen Spalten vorhanden?
     foreach ($columns_search as $value) {
         if (in_array($value, $colums_names) === false) {
             return false;
         }
     }
     return true;
 }