WP Admin UI Customize - Version 1.2.2

Version Description

Be able to changed more for the WP admin bar.

Download this release

Release Info

Developer gqevu6bsiz
Plugin Icon wp plugin WP Admin UI Customize
Version 1.2.2
Comparing to
See all releases

Code changes from version 1.2.1 to 1.2.2

inc/setting_admin_bar_menu.php CHANGED
@@ -50,13 +50,19 @@ wp_enqueue_style( $this->PageSlug , $this->Dir . dirname( dirname( plugin_basena
50
 
51
  <?php foreach( $this->Admin_bar as $node_id => $node ) : ?>
52
 
53
- <?php if( !empty( $node->parent ) && $node->parent != 'top-secondary' && $node->id != 'wp-logo-external' ) : ?>
 
 
 
 
54
 
55
  <?php if( $node->parent == 'wp-logo-external' ) : ?>
56
  <?php $ChildNode["wp-logo"][] = $node; ?>
57
  <?php else: ?>
58
  <?php $ChildNode[$node->parent][] = $node; ?>
59
  <?php endif; ?>
 
 
60
 
61
  <?php endif; ?>
62
 
@@ -72,7 +78,25 @@ wp_enqueue_style( $this->PageSlug , $this->Dir . dirname( dirname( plugin_basena
72
  <?php $pnsn[] = array( 'id' => $c_node->id , 'title' => $c_node->title , 'parent' => $p_node_id , 'href' => $c_node->href , 'group' => false , 'new' => false ); ?>
73
 
74
  <?php endforeach; ?>
75
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
76
  <?php endif; ?>
77
 
78
  <?php $menu_widget = array( 'id' => $p_node->id , 'title' => $p_node->title , 'parent' => '' , 'href' => $p_node->href , 'group' => false , 'new' => false , 'subnode' => $pnsn ); ?>
@@ -209,16 +233,76 @@ wp_enqueue_style( $this->PageSlug , $this->Dir . dirname( dirname( plugin_basena
209
  <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
210
  <div class="clear"></div>
211
 
212
- <p class="description"><?php _e ( 'Menu that can be added' , $this->ltd ); ?></p>
 
 
 
213
  <?php foreach( $this->Admin_bar as $node_id => $node ) : ?>
214
 
215
- <?php if( $node_id != 'top-secondary' ) : ?>
216
- <?php if( empty( $node->parent ) or $node->parent == 'top-secondary' ) : ?>
217
 
218
- <?php $menu_widget = array( 'id' => $node->id , 'title' => $node->title , 'parent' => '' , 'href' => $node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
219
- <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
220
 
221
- <?php endif; ?>
222
  <?php endif; ?>
223
 
224
  <?php endforeach; ?>
@@ -230,7 +314,7 @@ wp_enqueue_style( $this->PageSlug , $this->Dir . dirname( dirname( plugin_basena
230
  <?php if( !empty( $node->parent ) && $node->parent != 'top-secondary' && $node->id != 'user-info' && $node->id != 'user-actions' && $node->id != 'wp-logo-external' ) : ?>
231
 
232
  <?php $menu_widget = array( 'id' => $node->id , 'title' => $node->title , 'parent' => '' , 'href' => $node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
233
- <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
234
 
235
  <?php endif; ?>
236
 
50
 
51
  <?php foreach( $this->Admin_bar as $node_id => $node ) : ?>
52
 
53
+ <?php if( !empty( $node->parent ) && $node->parent != 'top-secondary' ) : ?>
54
+
55
+ <?php $ChildNode[$node->parent][] = $node; ?>
56
+ <?php
57
+ /*
58
 
59
  <?php if( $node->parent == 'wp-logo-external' ) : ?>
60
  <?php $ChildNode["wp-logo"][] = $node; ?>
61
  <?php else: ?>
62
  <?php $ChildNode[$node->parent][] = $node; ?>
63
  <?php endif; ?>
64
+ */
65
+ ?>
66
 
67
  <?php endif; ?>
68
 
78
  <?php $pnsn[] = array( 'id' => $c_node->id , 'title' => $c_node->title , 'parent' => $p_node_id , 'href' => $c_node->href , 'group' => false , 'new' => false ); ?>
79
 
80
  <?php endforeach; ?>
81
+
82
+ <?php endif; ?>
83
+
84
+ <?php if( !empty( $pnsn ) ) : ?>
85
+
86
+ <?php foreach( $pnsn as $key => $pnsn_node ) : ?>
87
+
88
+ <?php if( !empty( $ChildNode[$pnsn_node["id"]] ) ) : ?>
89
+
90
+ <?php foreach( $ChildNode[$pnsn_node["id"]] as $cs_node ) : ?>
91
+
92
+ <?php $pnsn[] = array( 'id' => $cs_node->id , 'title' => $cs_node->title , 'parent' => $p_node_id , 'href' => $cs_node->href , 'group' => false , 'new' => false ); ?>
93
+
94
+ <?php endforeach; ?>
95
+
96
+ <?php endif; ?>
97
+
98
+ <?php endforeach; ?>
99
+
100
  <?php endif; ?>
101
 
102
  <?php $menu_widget = array( 'id' => $p_node->id , 'title' => $p_node->title , 'parent' => '' , 'href' => $p_node->href , 'group' => false , 'new' => false , 'subnode' => $pnsn ); ?>
233
  <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
234
  <div class="clear"></div>
235
 
236
+ <p class="description" style="display: none;"><?php _e ( 'Menu that can be added' , $this->ltd ); ?></p>
237
+
238
+ <h4><?php _e( 'Left' , $this->ltd ); ?><?php _e( 'Menus' ); ?></h4>
239
+
240
  <?php foreach( $this->Admin_bar as $node_id => $node ) : ?>
241
 
242
+ <?php if( empty( $node->parent ) && $node_id != 'top-secondary' ) : ?>
 
243
 
244
+ <?php // left parent menu ?>
245
+ <?php $menu_widget = array( 'id' => $node->id , 'title' => $node->title , 'parent' => '' , 'href' => $node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
246
+ <p class="description"><?php echo $node_id; ?></p>
247
+ <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
248
+
249
+ <?php foreach( $this->Admin_bar as $child_node_id => $child_node ) : ?>
250
+
251
+ <?php if( $child_node->parent == $node_id ) : ?>
252
+
253
+ <?php // left child menu ?>
254
+ <?php if( !empty( $child_node->href ) ) : ?>
255
+ <?php $menu_widget = array( 'id' => $child_node->id , 'title' => $child_node->title , 'parent' => '' , 'href' => $child_node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
256
+ <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
257
+ <?php endif; ?>
258
+
259
+ <?php foreach( $this->Admin_bar as $child_sub_node_id => $child_sub_node ) : ?>
260
+
261
+ <?php if( $child_sub_node->parent == $child_node_id ) : ?>
262
+
263
+ <?php // left child sub menu ?>
264
+ <?php if( !empty( $child_sub_node->href ) ) : ?>
265
+ <?php $menu_widget = array( 'id' => $child_sub_node->id , 'title' => $child_sub_node->title , 'parent' => '' , 'href' => $child_sub_node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
266
+ <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
267
+ <?php endif; ?>
268
+
269
+ <?php endif; ?>
270
+
271
+ <?php endforeach; ?>
272
+
273
+ <?php endif; ?>
274
+
275
+ <?php endforeach; ?>
276
+
277
+ <div class="clear"></div>
278
+
279
+ <?php endif; ?>
280
+
281
+ <?php endforeach; ?>
282
+
283
+ <div class="clear"></div>
284
+
285
+ <h4><?php _e( 'Right' , $this->ltd ); ?><?php _e( 'Menus' ); ?></h4>
286
+
287
+ <?php foreach( $this->Admin_bar as $node_id => $node ) : ?>
288
+
289
+ <?php if( $node->parent == 'top-secondary' ) : ?>
290
+
291
+ <p class="description"><?php echo $node_id; ?></p>
292
+ <?php $menu_widget = array( 'id' => $node->id , 'title' => $node->title , 'parent' => '' , 'href' => $node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
293
+ <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
294
+
295
+ <?php foreach( $this->Admin_bar as $child_node_id => $child_node ) : ?>
296
+
297
+ <?php if( $child_node->parent == 'user-actions' ) : ?>
298
+ <?php $menu_widget = array( 'id' => $child_node->id , 'title' => $child_node->title , 'parent' => '' , 'href' => $child_node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
299
+ <?php $this->admin_bar_menu_widget( $menu_widget ); ?>
300
+ <?php endif; ?>
301
+
302
+ <?php endforeach; ?>
303
+
304
+ <div class="clear"></div>
305
 
 
306
  <?php endif; ?>
307
 
308
  <?php endforeach; ?>
314
  <?php if( !empty( $node->parent ) && $node->parent != 'top-secondary' && $node->id != 'user-info' && $node->id != 'user-actions' && $node->id != 'wp-logo-external' ) : ?>
315
 
316
  <?php $menu_widget = array( 'id' => $node->id , 'title' => $node->title , 'parent' => '' , 'href' => $node->href , 'group' => false , 'new' => true , 'subnode' => false ); ?>
317
+ <?php //$this->admin_bar_menu_widget( $menu_widget ); ?>
318
 
319
  <?php endif; ?>
320
 
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === WP Admin UI Customize ===
2
  Contributors: gqevu6bsiz
3
- Donate link: http://gqevu6bsiz.chicappa.jp/please-donation/?utm_source=wporg&utm_medium=donate&utm_content=wauc&utm_campaign=1_2_1
4
  Tags: admin, post, posts, page, option, sitemenu, menu, custom, customize, dashboard, admin_bar
5
  Requires at least: 3.4.2
6
  Tested up to: 3.5.1
7
- Stable tag: 1.2.1
8
  License: GPL2
9
 
10
  Customize the management screen UI.
@@ -49,6 +49,9 @@ These to Customization is possible.
49
 
50
  == Changelog ==
51
 
 
 
 
52
  = 1.2.1 =
53
  fixed because there was a mistake in the notation.
54
  Changed the layout.
1
  === WP Admin UI Customize ===
2
  Contributors: gqevu6bsiz
3
+ Donate link: http://gqevu6bsiz.chicappa.jp/please-donation/?utm_source=wporg&utm_medium=donate&utm_content=wauc&utm_campaign=1_2_2
4
  Tags: admin, post, posts, page, option, sitemenu, menu, custom, customize, dashboard, admin_bar
5
  Requires at least: 3.4.2
6
  Tested up to: 3.5.1
7
+ Stable tag: 1.2.2
8
  License: GPL2
9
 
10
  Customize the management screen UI.
49
 
50
  == Changelog ==
51
 
52
+ = 1.2.2 =
53
+ Be able to changed more for the WP admin bar.
54
+
55
  = 1.2.1 =
56
  fixed because there was a mistake in the notation.
57
  Changed the layout.
wp-admin-ui-customize.php CHANGED
@@ -3,9 +3,9 @@
3
  Plugin Name: WP Admin UI Customize
4
  Description: It is an excellent plugin to customize the management screen.
5
  Plugin URI: http://wordpress.org/extend/plugins/wp-admin-ui-customize/
6
- Version: 1.2.1
7
  Author: gqevu6bsiz
8
- Author URI: http://gqevu6bsiz.chicappa.jp/?utm_source=use_plugin&utm_medium=list&utm_content=wauc&utm_campaign=1_2_1
9
  Text Domain: wauc
10
  Domain Path: /languages
11
  */
@@ -45,7 +45,7 @@ class WP_Admin_UI_Customize
45
 
46
 
47
  function __construct() {
48
- $this->Ver = '1.2.1';
49
  $this->Name = 'WP Admin UI Customize';
50
  $this->Dir = WP_PLUGIN_URL . '/' . dirname( plugin_basename( __FILE__ ) ) . '/';
51
  $this->ltd = 'wauc';
@@ -241,6 +241,7 @@ class WP_Admin_UI_Customize
241
  // SetList
242
  function admin_bar_default_load( $wp_admin_bar ) {
243
  global $wp_admin_bar;
 
244
  $this->Admin_bar = $wp_admin_bar->get_nodes();
245
 
246
  }
@@ -549,7 +550,7 @@ class WP_Admin_UI_Customize
549
  }
550
  $title = "";
551
  if( !empty( $node["title"] ) ) {
552
- $title = $node["title"];
553
  }
554
  $href = "";
555
  if( !empty( $node["href"] ) ) {
@@ -843,18 +844,15 @@ class WP_Admin_UI_Customize
843
  unset( $GetData["UPFN"] );
844
  if( !empty( $GetData ) ) {
845
 
846
- $remove_menu = array( 'wp-logo' , 'site-name' , 'user-actions' , 'user-info' , 'edit-profile' , 'logout' , 'my-account' , 'about' , 'wporg' , 'documentation' , 'support-forums' , 'feedback' , 'comments' , 'updates' , 'new-content' , 'new-post' , 'new-media' , 'new-link' , 'new-page' , 'new-user' , 'view-site' );
847
-
848
- $cpts = (array) get_post_types( array( 'show_in_admin_bar' => true , '_builtin' => false ), 'names' );
849
- foreach($cpts as $cpt) {
850
- $remove_menu[] = 'new-' . $cpt;
851
- }
852
-
853
  // remove all nodes
854
- foreach( $remove_menu as $nid ) {
855
- $wp_admin_bar->remove_menu( $nid );
 
 
 
856
  }
857
 
 
858
  foreach($GetData as $Boxtype => $allnodes) {
859
  foreach($allnodes as $depth => $nodes) {
860
  foreach($nodes as $node) {
3
  Plugin Name: WP Admin UI Customize
4
  Description: It is an excellent plugin to customize the management screen.
5
  Plugin URI: http://wordpress.org/extend/plugins/wp-admin-ui-customize/
6
+ Version: 1.2.2
7
  Author: gqevu6bsiz
8
+ Author URI: http://gqevu6bsiz.chicappa.jp/?utm_source=use_plugin&utm_medium=list&utm_content=wauc&utm_campaign=1_2_2
9
  Text Domain: wauc
10
  Domain Path: /languages
11
  */
45
 
46
 
47
  function __construct() {
48
+ $this->Ver = '1.2.2';
49
  $this->Name = 'WP Admin UI Customize';
50
  $this->Dir = WP_PLUGIN_URL . '/' . dirname( plugin_basename( __FILE__ ) ) . '/';
51
  $this->ltd = 'wauc';
241
  // SetList
242
  function admin_bar_default_load( $wp_admin_bar ) {
243
  global $wp_admin_bar;
244
+
245
  $this->Admin_bar = $wp_admin_bar->get_nodes();
246
 
247
  }
550
  }
551
  $title = "";
552
  if( !empty( $node["title"] ) ) {
553
+ $title = stripslashes( $node["title"] );
554
  }
555
  $href = "";
556
  if( !empty( $node["href"] ) ) {
844
  unset( $GetData["UPFN"] );
845
  if( !empty( $GetData ) ) {
846
 
 
 
 
 
 
 
 
847
  // remove all nodes
848
+ $All_Nodes = $wp_admin_bar->get_nodes();
849
+ foreach( $All_Nodes as $node ) {
850
+ if( $node->id != 'top-secondary' ) {
851
+ $wp_admin_bar->remove_node( $node->id );
852
+ }
853
  }
854
 
855
+ // add nodes
856
  foreach($GetData as $Boxtype => $allnodes) {
857
  foreach($allnodes as $depth => $nodes) {
858
  foreach($nodes as $node) {