- removed "About" page;

- added tooltips to Profile menu;
- some fixes;
This commit is contained in:
nikitozzzzzzz
2017-07-28 13:33:14 +03:00
parent 1db8a9ae3a
commit a0eca5f350
11 changed files with 17 additions and 224 deletions
+1 -20
View File
@@ -8,15 +8,10 @@ if ( ! defined( 'ABSPATH' ) ) exit;
if ( ! class_exists( 'Admin_Menu' ) ) {
class Admin_Menu {
var $about_tabs = array();
function __construct() {
$this->slug = 'ultimatemember';
$this->about_tabs['about'] = 'About';
$this->about_tabs['start'] = 'Getting Started';
add_action('admin_menu', array(&$this, 'primary_admin_menu'), 0);
add_action('admin_menu', array(&$this, 'secondary_menu_items'), 1000);
add_action('admin_menu', array(&$this, 'extension_menu'), 9999);
@@ -34,7 +29,6 @@ if ( ! class_exists( 'Admin_Menu' ) ) {
// Add the dashboard pages
$um_pages[] = 'toplevel_page_ultimatemember';
$um_pages[] = 'admin_page_ultimatemember-about';
$um_pages[] = 'ultimate-member_page_um_options';
$um_pages[] = 'edit-um_form';
$um_pages[] = 'edit-um_role';
@@ -104,11 +98,6 @@ if ( ! class_exists( 'Admin_Menu' ) ) {
add_action( 'load-' . $this->pagehook, array( &$this, 'on_load_page' ) );
add_submenu_page( $this->slug, __('Dashboard', $this->slug), __('Dashboard', $this->slug), 'manage_options', $this->slug, array(&$this, 'admin_page') );
foreach( $this->about_tabs as $k => $tab ) {
add_submenu_page( '_'. $k . '_um', sprintf(__('%s | Ultimate Member', $this->slug), $tab), sprintf(__('%s | Ultimate Member', $this->slug), $tab), 'manage_options', $this->slug . '-' . $k, array(&$this, 'admin_page') );
}
}
@@ -301,18 +290,10 @@ if ( ! class_exists( 'Admin_Menu' ) ) {
<?php
} else if ( $page == 'ultimatemember-extensions' ) {
} elseif ( $page == 'ultimatemember-extensions' ) {
include_once UM()->admin()->templates_path . 'extensions.php';
} else if ( $page == 'ultimatemember-about' ) {
include_once UM()->admin()->templates_path . 'welcome/about.php';
} else if ( $page == 'ultimatemember-start' ) {
include_once UM()->admin()->templates_path . 'welcome/start.php';
}
}
@@ -1170,6 +1170,8 @@ if ( ! class_exists( 'Admin_Settings' ) ) {
um_js_redirect( add_query_arg( array( 'page' => 'um_options', 'tab' => $current_tab ), admin_url( 'admin.php' ) ) );
}
echo '<div id="um-settings-wrap" class="wrap"><h2>Ultimate Member - Settings</h2>';
echo $this->generate_tabs_menu() . $this->generate_subtabs_menu( $current_tab );
do_action( "um_settings_page_before_" . $current_tab . "_" . $current_subtab . "_content" );
@@ -1182,6 +1184,14 @@ if ( ! class_exists( 'Admin_Settings' ) ) {
} else { ?>
<!-- <?php /*if ( empty( $settings_struct['sections'][$current_subtab] ) )
$title = $this->settings_structure[$current_tab]['title'];
else
$title = $this->settings_structure[$current_tab]['sections'][$current_subtab]['title'];
*/?>
<h3><?php /*echo $title */?></h3>-->
<form method="post" action="" name="um-settings-form" id="um-settings-form">
<input type="hidden" value="save" name="um-settings-action" />
@@ -1197,6 +1207,8 @@ if ( ! class_exists( 'Admin_Settings' ) ) {
</form>
<?php }
/*echo '</div>';*/
}