Added option to enable/disable the plugin admin bar

This commit is contained in:
ultimatemember
2014-12-21 18:34:47 +02:00
parent 386bb823df
commit c8c40fb28f
2 changed files with 16 additions and 4 deletions
+2
View File
@@ -33,6 +33,8 @@
global $wp_admin_bar;
if( !is_super_admin() || !is_admin_bar_showing() || is_admin() ) return;
if ( !um_get_option('wpadmin_um_bar') ) return;
$args = array(
'id' => 'um_parent',
+14 -4
View File
@@ -238,6 +238,16 @@ $this->sections[] = array(
'title' => __( 'Backend'),
'fields' => array(
array(
'id' => 'wpadmin_um_bar',
'type' => 'switch',
'title' => __( 'Show Ultimate Member in admin bar when browsing the frontend?' ),
'default' => 1,
'desc' => 'Control whether to show or hide the Ultimate Member admin bar when you are browsing the frontend.',
'on' => __('Yes','ultimatemember'),
'off' => __('No','ultimatemember'),
),
array(
'id' => 'panic_key',
'type' => 'text',
@@ -253,8 +263,8 @@ $this->sections[] = array(
'title' => __( 'Allow Backend Login Screen for Guests' ),
'default' => 1,
'desc' => 'Control whether guests are able to access the WP-admin login screen or not',
'on' => 'Yes',
'off' => 'No',
'on' => __('Yes','ultimatemember'),
'off' => __('No','ultimatemember'),
),
array(
@@ -285,8 +295,8 @@ $this->sections[] = array(
'title' => __( 'Allow Backend Register Screen for Guests' ),
'default' => 1,
'desc' => 'Control whether guests are able to access the WP-admin register screen or not',
'on' => 'Yes',
'off' => 'No',
'on' => __('Yes','ultimatemember'),
'off' => __('No','ultimatemember'),
),
array(