'); add_to_footer(''); $this->pagenum = (int)filter_input(INPUT_GET, 'pagenum'); $html = '
'; $html .= $this->MainHeader(); $html .= $this->MainSidebar(); $html .= '
'; $html .= '
'; $html .= renderNotices(getNotices()); $html .= '
'; $html .= CONTENT; $html .= '
'; $html .= $this->MainFooter(); if (!$this->IsMobile()) { $html .= $this->ControlSidebar(); } $html .= '
'; echo $html; } private function MainHeader() { $aidlink = fusion_get_aidlink(); $html = '
'; $html .= ''; $html .= ''; $html .= '
'; return $html; } private function MessagesMenu() { $locale = fusion_get_locale('', ALTE_LOCALE); $messages = $this->Messages(); $msg_icon = !empty($messages) ? ''.count($messages).'' : ''; $html = ''; return $html; } private function UserMenu() { $locale = fusion_get_locale(); $userdata = fusion_get_userdata(); $html = ''; return $html; } private function MainSidebar() { $locale = fusion_get_locale(); $userdata = fusion_get_userdata(); $useronline = $userdata['user_lastvisit'] >= time() - 900 ? TRUE : FALSE; $html = ''; return $html; } private function SearchAjax() { add_to_jquery('$("#search_pages").bind("keyup", function (e) { $.ajax({ url: "'.ADMIN.'includes/acp_search.php'.fusion_get_aidlink().'", method: "get", data: $.param({"pagestring": $(this).val()}), dataType: "json", beforeSend: function () { $("#ajax-loader").show(); }, success: function (e) { if ($("#search_pages").val() == "") { $("#adl").show(); $("#search_result").html(e).hide(); $("#search_result li").html(e).hide(); } else { var result = ""; if (!e.status) { $.each(e, function (i, data) { if (data) { result += "
  • \"" " + data.title + "
  • "; } }); } else { result = "
  • " + e.status + "
  • "; } $("#search_result").html(result).show(); $("#adl").hide(); } }, complete: function () { $("#ajax-loader").hide(); } }); });'); } private function SidebarMenu() { $locale = fusion_get_locale(); $aidlink = fusion_get_aidlink(); $admin_sections = Admins::getInstance()->getAdminSections(); $admin_pages = Admins::getInstance()->getAdminPages(); $html = ''; return $html; } private function MainFooter() { $locale = fusion_get_locale(); $html = ''; return $html; } private function ControlSidebar() { $locale = fusion_get_locale('', ALTE_LOCALE); add_to_footer(''); $html = '
    '; return $html; } public function Messages() { $userdata = fusion_get_userdata(); $result = dbquery(" SELECT message_id, message_subject, message_from, user_id, u.user_name, u.user_status, u.user_avatar, message_datestamp FROM ".DB_MESSAGES." INNER JOIN ".DB_USERS." u ON u.user_id=message_from WHERE message_to='".$userdata['user_id']."' AND message_user='".$userdata['user_id']."' AND message_read='0' AND message_folder='0' GROUP BY message_id "); if (dbcount("(message_id)", DB_MESSAGES, "message_to='".$userdata['user_id']."' AND message_user='".$userdata['user_id']."' AND message_read='0' AND message_folder='0'")) { if (dbrows($result) > 0) { while ($data = dbarray($result)) { $this->messages[] = [ 'link' => $data['message_id'], 'title' => $data['message_subject'], 'user' => [ 'user_id' => $data['user_id'], 'user_name' => $data['user_name'], 'user_status' => $data['user_status'], 'user_avatar' => $data['user_avatar'] ], 'datestamp' => timer($data['message_datestamp']) ]; } } } return $this->messages; } public function GetMessages() { return $this->messages; } public function IsMobile() { return preg_match("/(android|avantgo|blackberry|bolt|boost|cricket|docomo|fone|hiptop|mini|mobi|palm|phone|pie|tablet|up\.browser|up\.link|webos|wos)/i", $_SERVER['HTTP_USER_AGENT']); } public static function OpenTable($title = FALSE, $class = NULL, $bg = TRUE) { $html = ''; if (!empty($title)) { $html .= '
    '; $html .= '

    '.$title.'

    '; if (self::$breadcrumbs == FALSE) { $html .= render_breadcrumbs(); self::$breadcrumbs = TRUE; } $html .= '
    '; } $html .= '
    '; if ($bg == TRUE) $html .= '
    '; echo $html; } public static function CloseTable($bg = TRUE) { $html = ''; if ($bg === TRUE) $html .= '
    '; $html .= '
    '; echo $html; } }