Exemplo n.º 1
0
/**
 * Display admin menu
 *
 * @return string menu
 */
function admin_list_config_adminmenu()
{
    $act = "";
    unset($var);
    $var = array();
    //$var['general']['text'] = LIST_ADMIN_OPT_1;
    $var['list-new-recent-page']['text'] = LIST_ADMIN_OPT_2;
    $var['list-new-recent-menu']['text'] = LIST_ADMIN_OPT_3;
    $var['list-new-new-page']['text'] = LIST_ADMIN_OPT_4;
    $var['list-new-new-menu']['text'] = LIST_ADMIN_OPT_5;
    e_admin_menu(LIST_ADMIN_OPT_6 . '--id--list_new', 'list-new-recent-page', $var);
}
Exemplo n.º 2
0
function theme_adminmenu()
{
    global $mode;
    $mode = e_QUERY;
    $e107 =& e107::getInstance();
    $var['main']['text'] = TPVLAN_33;
    $var['main']['link'] = e_SELF;
    $var['admin']['text'] = TPVLAN_34;
    $var['admin']['link'] = e_SELF . "?admin";
    $var['choose']['text'] = TPVLAN_51;
    $var['choose']['link'] = e_SELF . "?choose";
    $var['upload']['text'] = TPVLAN_38;
    $var['upload']['link'] = e_SELF . "?upload";
    $selected = e_QUERY ? e_QUERY : "main";
    e_admin_menu(TPVLAN_26, $selected, $var);
}
Exemplo n.º 3
0
function lancheck_adminmenu()
{
    include_lan(e_LANGUAGEDIR . e_LANGUAGE . "/admin/lan_language.php");
    global $action, $pref;
    if ($action == "") {
        $action = "tools";
    }
    if ($action == "modify") {
        $action = "db";
    }
    $var['main']['text'] = LAN_PREFS;
    $var['main']['link'] = e_ADMIN_ABS . "language.php";
    if (isset($pref['multilanguage']) && $pref['multilanguage']) {
        $var['db']['text'] = LANG_LAN_03;
        $var['db']['link'] = e_ADMIN_ABS . "language.php?db";
    }
    $var['tools']['text'] = ADLAN_CL_6;
    $var['tools']['link'] = e_ADMIN_ABS . "language.php?tools";
    e_admin_menu(ADLAN_132, $action, $var);
}
Exemplo n.º 4
0
 function sc_admin_nav($parm)
 {
     if (ADMIN) {
         global $ns, $pref, $array_functions, $tp;
         $e107_var = array();
         if (strstr(e_SELF, '/admin.php')) {
             $active_page = 'x';
         } else {
             $active_page = time();
         }
         $e107_var['x']['text'] = ADLAN_52;
         $e107_var['x']['link'] = e_ADMIN_ABS . 'admin.php';
         $e107_var['y']['text'] = ADLAN_53;
         $e107_var['y']['link'] = e_HTTP . "index.php";
         //$text .= show_admin_menu("",$active_page,$e107_var);
         $e107_var['afuncs']['text'] = ADLAN_93;
         $e107_var['afuncs']['link'] = '';
         /* SUBLINKS */
         $tmp = array();
         foreach ($array_functions as $links_key => $links_value) {
             $tmp[$links_key]['text'] = $links_value[1];
             $tmp[$links_key]['link'] = $links_value[0];
         }
         $e107_var['afuncs']['sub'] = $tmp;
         /* SUBLINKS END */
         // Plugin links menu
         $xml = e107::getXml();
         $xml->filter = array('@attributes' => FALSE, 'administration' => FALSE);
         // .. and they're all going to need the same filter
         $nav_sql = new db();
         if ($nav_sql->db_Select('plugin', '*', 'plugin_installflag=1')) {
             $tmp = array();
             $e107_var['plugm']['text'] = ADLAN_95;
             $e107_var['plugm']['link'] = '';
             /* SUBLINKS */
             //Link Plugin Manager
             $tmp['plugm']['text'] = '<strong>' . ADLAN_98 . '</strong>';
             $tmp['plugm']['link'] = e_ADMIN . 'plugin.php';
             $tmp['plugm']['perm'] = 'P';
             while ($rowplug = $nav_sql->db_Fetch()) {
                 $plugin_id = $rowplug['plugin_id'];
                 $plugin_path = $rowplug['plugin_path'];
                 if (is_readable(e_PLUGIN . $plugin_path . '/plugin.xml')) {
                     $readFile = $xml->loadXMLfile(e_PLUGIN . $plugin_path . '/plugin.xml', true, true);
                     //	e107::loadLanFiles($plugin_path, 'admin');
                     $eplug_caption = $tp->toHTML($readFile['@attributes']['name'], FALSE, 'defs, emotes_off');
                     $eplug_conffile = $readFile['administration']['configFile'];
                 } elseif (is_readable(e_PLUGIN . $plugin_path . '/plugin.php')) {
                     include e_PLUGIN . $plugin_path . '/plugin.php';
                 }
                 // Links Plugins
                 if ($eplug_conffile) {
                     $tmp['plug_' . $plugin_id]['text'] = $eplug_caption;
                     $tmp['plug_' . $plugin_id]['link'] = e_PLUGIN . $plugin_path . '/' . $eplug_conffile;
                     $tmp['plug_' . $plugin_id]['perm'] = 'P' . $plugin_id;
                 }
                 unset($eplug_conffile, $eplug_name, $eplug_caption);
             }
             $e107_var['plugm']['sub'] = $tmp;
             $e107_var['plugm']['sort'] = true;
             /* SUBLINKS END */
             //$text .= show_admin_menu(ADLAN_95, time(), $e107_var, FALSE, TRUE, TRUE);
             unset($tmp);
         }
         $e107_var['lout']['text'] = LAN_LOGOUT;
         $e107_var['lout']['link'] = e_ADMIN_ABS . 'admin.php?logout';
         $text = e_admin_menu('', '', $e107_var);
         return $ns->tablerender(LAN_HEADER_01, $text, array('id' => 'admin_nav', 'style' => 'button_menu'), TRUE);
     }
 }
Exemplo n.º 5
0
 function pluginMenuOptions()
 {
     //	$e107 = &e107::getInstance();
     $var['installed']['text'] = EPL_ADLAN_22;
     $var['installed']['link'] = e_SELF;
     $var['avail']['text'] = EPL_ADLAN_23;
     $var['avail']['link'] = e_SELF . "?avail";
     //	$var['upload']['text'] = EPL_ADLAN_38;
     //	$var['upload']['link'] = e_SELF."?upload";
     $var['online']['text'] = "Search";
     $var['online']['link'] = e_SELF . "?mode=online";
     $keys = array_keys($var);
     $action = in_array($this->action, $keys) ? $this->action : "installed";
     e_admin_menu(ADLAN_98, $action, $var);
 }
Exemplo n.º 6
0
/**
 *	Admin menu options
 */
function banlist_adminmenu()
{
    $action = e_QUERY ? e_QUERY : 'list';
    $var['list']['text'] = BANLAN_14;
    // List existing bans
    $var['list']['link'] = e_SELF . '?list';
    $var['list']['perm'] = '4';
    $var['add']['text'] = BANLAN_25;
    // Add a new ban
    $var['add']['link'] = e_SELF . '?add';
    $var['add']['perm'] = '4';
    $var['white']['text'] = BANLAN_52;
    // List existing whitelist entries
    $var['white']['link'] = e_SELF . '?white';
    $var['white']['perm'] = '4';
    $var['whadd']['text'] = BANLAN_53;
    // Add a new whitelist entry
    $var['whadd']['link'] = e_SELF . '?whadd';
    $var['whadd']['perm'] = '4';
    $var['transfer']['text'] = BANLAN_35;
    $var['transfer']['link'] = e_SELF . '?transfer';
    $var['transfer']['perm'] = '4';
    if (getperms('0')) {
        $var['times']['text'] = BANLAN_15;
        $var['times']['link'] = e_SELF . '?times';
        $var['times']['perm'] = '0';
        $var['options']['text'] = LAN_OPTIONS;
        $var['options']['link'] = e_SELF . '?options';
        $var['options']['perm'] = '0';
        $var['banlog']['text'] = BANLAN_81;
        $var['banlog']['link'] = e_SELF . '?banlog';
        $var['banlog']['perm'] = '0';
    }
    e_admin_menu(BANLAN_16, $action, $var);
}
Exemplo n.º 7
0
 /**
  * Generic Admin Menu Generator
  * @return string
  */
 function renderMenu()
 {
     $tp = e107::getParser();
     $var = array();
     $selected = false;
     foreach ($this->adminMenu as $key => $val) {
         $tmp = explode('/', trim($key, '/'), 3);
         // sync with mode/route access
         if (!$this->checkModeAccess($tmp[0]) || !$this->checkRouteAccess($tmp[0] . '/' . $tmp[1])) {
             continue;
         }
         // custom 'selected' check
         if (isset($val['selected']) && $val['selected']) {
             $selected = $val['selected'] === true ? $key : $val['selected'];
         }
         foreach ($val as $k => $v) {
             switch ($k) {
                 case 'caption':
                     $k2 = 'text';
                     $v = defset($v, $v);
                     break;
                 case 'url':
                     $k2 = 'link';
                     $v = $tp->replaceConstants($v, 'abs') . '?mode=' . $tmp[0] . '&amp;action=' . $tmp[1];
                     break;
                 case 'uri':
                     $k2 = 'link';
                     $v = $tp->replaceConstants($v, 'abs');
                     break;
                 default:
                     $k2 = $k;
                     break;
             }
             $var[$key][$k2] = $v;
         }
         // TODO slide down menu options?
         if (!vartrue($var[$key]['link'])) {
             $var[$key]['link'] = e_SELF . '?mode=' . $tmp[0] . '&amp;action=' . $tmp[1];
             // FIXME - URL based on $modes, remove url key
         }
         /*$var[$key]['text'] = $val['caption'];
         		$var[$key]['link'] = (vartrue($val['url']) ? $tp->replaceConstants($val['url'], 'abs') : e_SELF).'?mode='.$tmp[0].'&action='.$tmp[1];
         		$var[$key]['perm'] = $val['perm'];	*/
     }
     if (empty($var)) {
         return '';
     }
     $request = $this->getRequest();
     if (!$selected) {
         $selected = $request->getMode() . '/' . $request->getAction();
     }
     $selected = vartrue($this->adminMenuAliases[$selected], $selected);
     return e_admin_menu($this->menuTitle, $selected, $var);
 }
Exemplo n.º 8
0
Arquivo: db.php Projeto: notzen/e107
function db_adminmenu()
{
    global $st;
    foreach ($st->_options as $key => $val) {
        $var[$key]['text'] = $val['label'];
        $var[$key]['link'] = e_SELF . "?mode=" . $key;
    }
    e_admin_menu(DBLAN_10, $_GET['mode'], $var);
}
Exemplo n.º 9
0
 function sc_admin_menumanager()
 {
     global $pref;
     $action = "";
     $var['menumanager']['text'] = LAN_MENULAYOUT;
     $var['menumanager']['link'] = e_ADMIN_ABS . 'menus.php';
     if (vartrue($pref['menuconfig_list'])) {
         foreach ($pref['menuconfig_list'] as $name => $val) {
             $var[$name]['text'] = str_replace(":", " / ", $val['name']);
             $var[$name]['link'] = e_PLUGIN_ABS . $val['link'];
         }
     }
     foreach ($var as $key => $link) {
         if (strpos(e_SELF, $link['link'])) {
             $action = $key;
         }
     }
     if (!$action) {
         return;
     }
     //		$keys = array_keys($var);
     //	$action = (in_array($this->action,$keys)) ? $this->action : "installed";
     e_admin_menu(ADLAN_6, $action, $var);
 }
Exemplo n.º 10
0
function language_adminmenu()
{
    global $pref;
    $action = e_QUERY;
    if ($action == "") {
        $action = "main";
    }
    if ($action == "modify") {
        $action = "db";
    }
    $var['main']['text'] = LAN_PREFS;
    $var['main']['link'] = e_SELF;
    if (isset($pref['multilanguage']) && $pref['multilanguage']) {
        $var['db']['text'] = LANG_LAN_03;
        $var['db']['link'] = e_SELF . "?db";
    }
    //	$lcnt = explode(",", e_LANLIST);
    //	if (count($lcnt) > 1)
    //	{
    $var['tools']['text'] = LANG_LAN_21;
    $var['tools']['link'] = e_SELF . "?tools";
    //	}
    e_admin_menu(ADLAN_132, $action, $var);
}
Exemplo n.º 11
0
function admin_log_adminmenu()
{
    if (e_QUERY) {
        $tmp = explode(".", e_QUERY);
        $action = $tmp[0];
    }
    if ($action == "") {
        $action = "adminlog";
    }
    $var['adminlog']['text'] = RL_LAN_030;
    $var['adminlog']['link'] = "admin_log.php?adminlog";
    $var['auditlog']['text'] = RL_LAN_062;
    $var['auditlog']['link'] = "admin_log.php?auditlog";
    $var['rolllog']['text'] = RL_LAN_002;
    $var['rolllog']['link'] = "admin_log.php?rolllog";
    $var['downlog']['text'] = RL_LAN_067;
    $var['downlog']['link'] = "admin_log.php?downlog";
    $var['detailed']['text'] = RL_LAN_091;
    $var['detailed']['link'] = "admin_log.php?detailed";
    // Deprecated by Comments Manager.
    /*
    	$var['comments']['text'] = 'Comments';
    	$var['comments']['link'] = "admin_log.php?comments";
    */
    $var['config']['text'] = LAN_OPTIONS;
    $var['config']['link'] = "admin_log.php?config";
    /* XXX - why?!
    	if($action == 'comments')
    	{
    		$var['users']['text'] = RL_LAN_115;
    		$var['users']['link'] = "users.php";
    	}
    	*/
    e_admin_menu(RL_LAN_005, $action, $var);
}
Exemplo n.º 12
0
 function show_options($action)
 {
     $action = varset($_GET['mode'], 'list');
     $var['list']['text'] = $this->listCaption;
     $var['list']['link'] = e_SELF . "?mode=list";
     $var['list']['perm'] = "0";
     $var['create']['text'] = $this->createCaption;
     $var['create']['link'] = e_SELF . "?mode=create";
     $var['create']['perm'] = 0;
     /*
     		$var['options']['text'] = LAN_OPTIONS;
     		$var['options']['link'] = e_SELF."?options";
     		$var['options']['perm'] = "0";*/
     e_admin_menu($this->pluginTitle, $action, $var);
 }
Exemplo n.º 13
0
function prefs_adminmenu()
{
    $var['core-prefs-main']['text'] = PRFLAN_1;
    $var['core-prefs-display']['text'] = PRFLAN_13;
    $var['core-prefs-admindisp']['text'] = PRFLAN_77;
    $var['core-prefs-date']['text'] = PRFLAN_21;
    $var['core-prefs-registration']['text'] = PRFLAN_28;
    $var['core-prefs-signup']['text'] = PRFLAN_19;
    $var['core-prefs-sociallogin']['text'] = "Social Logins";
    $var['core-prefs-textpost']['text'] = PRFLAN_101;
    $var['core-prefs-security']['text'] = PRFLAN_47;
    $var['core-prefs-comments']['text'] = PRFLAN_210;
    $var['core-prefs-uploads']['text'] = "File Uploading";
    // TODO LAN
    $var['core-prefs-javascript']['text'] = "Javascript Framework";
    // TODO LAN
    $var['core-prefs-advanced']['text'] = PRFLAN_149;
    e_admin_menu(LAN_OPTIONS . '--id--prev_nav', 'core-prefs-main', $var);
}
Exemplo n.º 14
0
function admin_banner_adminmenu()
{
    $qry = e_QUERY;
    $act = vartrue($qry, 'main');
    $var['main']['text'] = BNRLAN_58;
    $var['main']['link'] = e_SELF;
    $var['create']['text'] = BNRLAN_59;
    $var['create']['link'] = e_SELF . "?create";
    $var['menu']['text'] = BNRLAN_61;
    $var['menu']['link'] = e_SELF . "?menu";
    e_admin_menu(BNRLAN_62, $act, $var);
}
Exemplo n.º 15
0
function search_adminmenu()
{
    $query = e_QUERY;
    $action = vartrue($query, 'main');
    $var['main']['text'] = SEALAN_41;
    $var['main']['link'] = e_SELF;
    $var['settings']['text'] = SEALAN_42;
    $var['settings']['link'] = e_SELF . "?settings";
    e_admin_menu(SEALAN_40, $action, $var);
}
Exemplo n.º 16
0
Arquivo: boot.php Projeto: notzen/e107
 function show_admin_menu($title, $active_page, $e107_vars, $js = FALSE, $sub_link = FALSE, $sortlist = FALSE)
 {
     return e_admin_menu($title, $active_page, $e107_vars, false, false, $sortlist);
 }