/** * The credits section in admin panel. * * What it does: * - Determines the current level of support functions from the server, such as * current level of caching engine or graphics librayrs installed. * - Accessed by ?action=admin;area=credits */ public function action_credits() { global $forum_version, $txt, $scripturl, $context, $user_info; // We need a little help from our friends require_once SUBSDIR . '/Membergroups.subs.php'; require_once SUBSDIR . '/Who.subs.php'; require_once SUBSDIR . '/Admin.subs.php'; // You have to be able to do at least one of the below to see this page. isAllowedTo(array('admin_forum', 'manage_permissions', 'moderate_forum', 'manage_membergroups', 'manage_bans', 'send_mail', 'edit_news', 'manage_boards', 'manage_smileys', 'manage_attachments')); // Find all of this forum's administrators... if (listMembergroupMembers_Href($context['administrators'], 1, 32) && allowedTo('manage_membergroups')) { // Add a 'more'-link if there are more than 32. $context['more_admins_link'] = '<a href="' . $scripturl . '?action=moderate;area=viewgroups;sa=members;group=1">' . $txt['more'] . '</a>'; } // Load credits. $context[$context['admin_menu_name']]['tab_data'] = array('title' => $txt['support_credits_title'], 'help' => '', 'description' => ''); loadLanguage('Who'); $context += prepareCreditsData(); // This makes it easier to get the latest news with your time format. $context['time_format'] = urlencode($user_info['time_format']); $context['forum_version'] = $forum_version; // Get a list of current server versions. $checkFor = array('gd', 'imagick', 'db_server', 'mmcache', 'eaccelerator', 'zend', 'apc', 'memcache', 'xcache', 'opcache', 'php', 'server'); $context['current_versions'] = getServerVersions($checkFor); $context['can_admin'] = allowedTo('admin_forum'); $context['sub_template'] = 'credits'; $context['page_title'] = $txt['support_credits_title']; // Load in the admin quick tasks $context['quick_admin_tasks'] = getQuickAdminTasks(); }
/** * It prepares credit and copyright information for the credits page or the admin page. * Accessed by ?action=who;sa=credits * @uses Who language file * @uses Who template, credits sub template */ public function action_credits() { global $context, $txt; require_once SUBSDIR . '/Who.subs.php'; loadLanguage('Who'); $context += prepareCreditsData(); loadTemplate('Who'); $context['sub_template'] = 'credits'; $context['robot_no_index'] = true; $context['page_title'] = $txt['credits']; }