Ozh' Admin Drop Down Menu - Version 3.5.4

Version Description

Download this release

Release Info

Developer ozh
Plugin Icon 128x128 Ozh' Admin Drop Down Menu
Version 3.5.4
Comparing to
See all releases

Code changes from version 3.4.5 to 3.5.4

inc/adminmenu.css.php CHANGED
@@ -247,6 +247,8 @@ header('Content-type:text/css');
247
  #oam_menu-users:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -301px -3px no-repeat;}
248
  #oam_menu-tools div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -35px no-repeat;}
249
  #oam_menu-tools:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -3px no-repeat;}
 
 
250
  #oam_menu-settings div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -241px -35px no-repeat;}
251
  #oam_menu-settings:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -241px -3px no-repeat;}
252
  #ozhmenu img.wp-menu-image {float:<?php echo $dir; ?>;opacity:0.6;padding:5px 1px 0;filter:alpha(opacity=60);}
247
  #oam_menu-users:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -301px -3px no-repeat;}
248
  #oam_menu-tools div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -35px no-repeat;}
249
  #oam_menu-tools:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -3px no-repeat;}
250
+ #oam_menu-update div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -35px no-repeat;}
251
+ #oam_menu-update:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -211px -3px no-repeat;}
252
  #oam_menu-settings div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -241px -35px no-repeat;}
253
  #oam_menu-settings:hover div.wp-menu-image {background:transparent url(<?php echo $admin; ?>/images/menu.png) -241px -3px no-repeat;}
254
  #ozhmenu img.wp-menu-image {float:<?php echo $dir; ?>;opacity:0.6;padding:5px 1px 0;filter:alpha(opacity=60);}
inc/adminmenu.js DELETED
@@ -1,78 +0,0 @@
1
- /*
2
- Part of Plugin: Ozh' Admin Drop Down Menu
3
- http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/
4
- */
5
-
6
- jQuery(document).ready(function() {
7
- if (oam_adminmenu) {
8
- // Remove unnecessary links in the top right corner
9
- var ozhmenu_uselesslinks = jQuery('#user_info p').html();
10
- ozhmenu_uselesslinks = ozhmenu_uselesslinks.replace(/<span id="gears-menu"><a href="tools.php">Turbo<\/a><\/span> \|/i, ''); // remove Turbo link
11
- jQuery('#user_info p').html(ozhmenu_uselesslinks);
12
- jQuery('#user_info').css('z-index','81');
13
- // jQueryfication of the Son of Suckerfish Drop Down Menu for MSIE6 (die die die)
14
- // Original at: http://www.htmldog.com/articles/suckerfish/dropdowns/
15
- if (jQuery.browser.msie && jQuery.browser.version < 7) {
16
- jQuery('#ozhmenu li.ozhmenu_toplevel').each(function() {
17
- jQuery(this).mouseover(function(){
18
- jQuery(this).addClass('ozhmenu_over');
19
- if (jQuery.browser.msie) {ozhmenu_hide_selects(true);}
20
- }).mouseout(function(){
21
- jQuery(this).removeClass('ozhmenu_over');
22
- if (jQuery.browser.msie) {ozhmenu_hide_selects(false);}
23
- });
24
- });
25
- }
26
- // Function to hide <select> elements (display bug with MSIE)
27
- function ozhmenu_hide_selects(hide) {
28
- var hidden = (hide) ? 'hidden' : 'visible';
29
- jQuery('select').css('visibility',hidden);
30
- }
31
-
32
- // Dynamically float submenu elements if there are too many
33
- var menuresize = {};
34
- jQuery('.ozhmenu_toplevel span').mouseover(
35
- function(){
36
- var target = jQuery(this).parent().parent().attr('id');
37
- if (!target || menuresize[target]) return; // we've hovered a speech bubble, or we've already reworked this menu
38
- var menulength = jQuery('#'+target+' ul li').length;
39
- if (menulength > oam_toomanypluygins) {
40
- var maxw = 0;
41
- // float every item to the left and get the biggest size
42
- jQuery('#'+target+' ul li').each(function(){
43
- jQuery(this).css('float', 'left');
44
- maxw = Math.max(parseInt(jQuery(this).css('width')), maxw);
45
- });
46
- // Resize the whole submenu
47
- if (maxw) {
48
- var cols = parseInt(menulength / oam_toomanypluygins)+1;
49
- jQuery('#'+target+' ul li').each(function(){
50
- jQuery(this).css('width', maxw+'px');
51
- });
52
- // Give the submenu a width = (max item width)*number of columns + 20px between each column
53
- jQuery('#'+target+' ul').css('width', ( cols*maxw + (20*(cols-1)) )+'px');
54
- }
55
- }
56
- menuresize[target] = true;
57
- }
58
- );
59
-
60
- // #screen-meta move under our menu
61
- jQuery('#ozhmenu_wrap').after(jQuery('#screen-meta').clone(true).attr('id', 'screen-meta-ozhmenucopy')); // copy after menu and name it screen-meta-ozhmenucopy
62
- jQuery('#screen-meta').remove(); // delete original
63
- jQuery('#screen-meta-ozhmenucopy').attr('id', 'screen-meta').css('display','block'); // rename & show
64
- /**/
65
-
66
- // WPMU : behavior for the "All my blogs" link
67
- jQuery( function($) {
68
- var form = $( '#all-my-blogs' ).submit( function() { document.location = form.find( 'select' ).val(); return false;} );
69
- var tab = $('#all-my-blogs-tab a');
70
- var head = $('#wphead');
71
- $('.blog-picker-toggle').click( function() {
72
- form.toggle();
73
- tab.toggleClass( 'current' );
74
- return false;
75
- });
76
- } );
77
- }
78
- })
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
inc/core.php CHANGED
@@ -59,7 +59,7 @@ function wp_ozh_adminmenu () {
59
  $fullstyle = 'inline';
60
  }
61
 
62
- if ( $submenu_as_parent && !empty($submenu[$item[2]]) ) {
63
  $submenu[$item[2]] = array_values($submenu[$item[2]]); // Re-index.
64
  $menu_hook = get_plugin_page_hook($submenu[$item[2]][0][2], $item[2]);
65
  if ( ( ('index.php' != $submenu[$item[2]][0][2]) && file_exists(WP_PLUGIN_DIR . "/{$submenu[$item[2]][0][2]}") ) || !empty($menu_hook)) {
@@ -100,6 +100,8 @@ function wp_ozh_adminmenu () {
100
 
101
  // Sub level menus
102
  if ( !empty($submenu[$item[2]]) ) {
 
 
103
  $ozh_menu .= "\n\t\t<ul$ulclass><li class='toplevel_label'>$anchor</li>\n";
104
  $first = true;
105
  foreach ( $submenu[$item[2]] as $sub_key => $sub_item ) {
@@ -157,6 +159,9 @@ function wp_ozh_adminmenu () {
157
 
158
  $subid = 'oamsub_'.wp_ozh_adminmenu_sanitize_id($sub_item[2]);
159
  $subanchor = strip_tags($sub_item[0]);
 
 
 
160
 
161
  $ozh_menu .= "\t\t\t<li class='ozhmenu_sublevel $icon' id='$subid'><a href='$suburl'$subclass>$subanchor</a></li>\n";
162
  }
@@ -171,11 +176,11 @@ function wp_ozh_adminmenu () {
171
  // Plugins: hack $ozh_menu now it's complete
172
  $ozh_menu = apply_filters( 'post_ozh_adminmenu_ozh_menu', $ozh_menu );
173
 
174
- if ($plugin_icons) {
175
  global $text_direction;
176
  $align = ($text_direction == 'rtl' ? 'right' : 'left');
177
  echo "\n".'<style type="text/css">'."\n";
178
- foreach($plugin_icons as $hook=>$icon) {
179
  $hook = plugin_basename($hook);
180
  //echo "#oamsub_$hook a {background-image:url($icon);}\n";
181
  echo "#oamsub_$hook a {background:url($icon) center $align no-repeat;}\n";
@@ -220,7 +225,7 @@ function wp_ozh_adminmenu_js() {
220
  unset( $defaults );
221
  }
222
  $plugin_url = wp_ozh_adminmenu_pluginurl();
223
- $insert_main_js = '<script src="'.$plugin_url.'inc/js/adminmenu.js" type="text/javascript"></script>';
224
 
225
  echo <<<JS
226
  <script type="text/javascript"><!--//--><![CDATA[//><!--
@@ -248,6 +253,7 @@ function wp_ozh_adminmenu_css() {
248
  $plugin = wp_ozh_adminmenu_pluginurl().'inc/';
249
  // query vars
250
  $query = array(
 
251
  'p' => wp_make_link_relative($plugin),
252
  'a' => wp_make_link_relative( get_admin_url() ),
253
  'i' => $wp_ozh_adminmenu['icons'],
@@ -306,6 +312,7 @@ function wp_ozh_adminmenu_init() {
306
  }
307
 
308
  $wp_ozh_adminmenu = array_merge($defaults, $wp_ozh_adminmenu);
 
309
  // Cannot have wpicons == 0 && compact == 1
310
  if ($wp_ozh_adminmenu['compact'] == 1)
311
  $wp_ozh_adminmenu['wpicons'] = 1;
@@ -401,7 +408,7 @@ function wp_ozh_adminmenu_processform() {
401
  foreach ($_POST as $k=>$v) {
402
  $k = str_replace('oam_','',$k);
403
  if (array_key_exists($k, $defaults)) {
404
- $options[$k] = attribute_escape($v);
405
  }
406
  }
407
 
59
  $fullstyle = 'inline';
60
  }
61
 
62
+ if ( isset( $submenu_as_parent ) && !empty( $submenu[$item[2]] ) ) {
63
  $submenu[$item[2]] = array_values($submenu[$item[2]]); // Re-index.
64
  $menu_hook = get_plugin_page_hook($submenu[$item[2]][0][2], $item[2]);
65
  if ( ( ('index.php' != $submenu[$item[2]][0][2]) && file_exists(WP_PLUGIN_DIR . "/{$submenu[$item[2]][0][2]}") ) || !empty($menu_hook)) {
100
 
101
  // Sub level menus
102
  if ( !empty($submenu[$item[2]]) ) {
103
+ if( !isset( $ulclass ) )
104
+ $ulclass = '';
105
  $ozh_menu .= "\n\t\t<ul$ulclass><li class='toplevel_label'>$anchor</li>\n";
106
  $first = true;
107
  foreach ( $submenu[$item[2]] as $sub_key => $sub_item ) {
159
 
160
  $subid = 'oamsub_'.wp_ozh_adminmenu_sanitize_id($sub_item[2]);
161
  $subanchor = strip_tags($sub_item[0]);
162
+
163
+ if( !isset( $icon ) )
164
+ $icon = '';
165
 
166
  $ozh_menu .= "\t\t\t<li class='ozhmenu_sublevel $icon' id='$subid'><a href='$suburl'$subclass>$subanchor</a></li>\n";
167
  }
176
  // Plugins: hack $ozh_menu now it's complete
177
  $ozh_menu = apply_filters( 'post_ozh_adminmenu_ozh_menu', $ozh_menu );
178
 
179
+ if ( isset( $plugin_icons ) ) {
180
  global $text_direction;
181
  $align = ($text_direction == 'rtl' ? 'right' : 'left');
182
  echo "\n".'<style type="text/css">'."\n";
183
+ foreach( $plugin_icons as $hook=>$icon ) {
184
  $hook = plugin_basename($hook);
185
  //echo "#oamsub_$hook a {background-image:url($icon);}\n";
186
  echo "#oamsub_$hook a {background:url($icon) center $align no-repeat;}\n";
225
  unset( $defaults );
226
  }
227
  $plugin_url = wp_ozh_adminmenu_pluginurl();
228
+ $insert_main_js = '<script src="'.$plugin_url.'inc/js/adminmenu.js?v='. OZH_MENU_VER .'" type="text/javascript"></script>';
229
 
230
  echo <<<JS
231
  <script type="text/javascript"><!--//--><![CDATA[//><!--
253
  $plugin = wp_ozh_adminmenu_pluginurl().'inc/';
254
  // query vars
255
  $query = array(
256
+ 'v' => OZH_MENU_VER,
257
  'p' => wp_make_link_relative($plugin),
258
  'a' => wp_make_link_relative( get_admin_url() ),
259
  'i' => $wp_ozh_adminmenu['icons'],
312
  }
313
 
314
  $wp_ozh_adminmenu = array_merge($defaults, $wp_ozh_adminmenu);
315
+
316
  // Cannot have wpicons == 0 && compact == 1
317
  if ($wp_ozh_adminmenu['compact'] == 1)
318
  $wp_ozh_adminmenu['wpicons'] = 1;
408
  foreach ($_POST as $k=>$v) {
409
  $k = str_replace('oam_','',$k);
410
  if (array_key_exists($k, $defaults)) {
411
+ $options[$k] = esc_attr( $v );
412
  }
413
  }
414
 
inc/icons.php CHANGED
@@ -5,36 +5,38 @@ http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/
5
  */
6
 
7
  $wp_ozh_adminmenu['icon_names'] = array(
8
- /* Super Admin */
9
- 'ms-admin.php' => 'tux',
10
- 'ms-sites.php' => 'world_link',
11
- 'ms-users.php' => 'user_go',
12
- 'ms-themes.php' => 'layers',
13
- 'ms-options.php' => 'computer_edit',
14
- 'ms-upgrade-network.php' => 'lightning_go',
15
  /* Dashboard */
16
  'index.php' => 'application_view_tile',
17
  'my-sites.php' => 'world',
18
  'update-core' => 'wordpress_icon',
19
  'akismet-stats-display' => 'comment_delete', // Akismet
 
20
  /* Posts */
21
  'edit.php' => 'pencil',
22
  'post-new.php' => 'page_white_edit',
23
- 'edit-tags.php' => 'tag_blue_edit',
24
  'edit-tags.php?taxonomy=category' => 'tag_red',
25
  'edit-tags.php?taxonomy=post_tag' => 'tag_blue_edit',
 
26
  /* Media */
27
  'upload.php' => 'image',
28
  'media-new.php' => 'image_add',
 
29
  /* Links */
30
  'link-manager.php' => 'link',
31
  'link-add.php' => 'link_add',
32
- 'edit-link-categories.php' => 'link_edit',
 
 
33
  /* Pages */
34
  'edit.php?post_type=page' => 'page_edit',
35
  'post-new.php?post_type=page' => 'page_edit',
 
36
  /* Comments */
37
  'edit-comments.php' => 'comment',
 
38
  /* Appearance */
39
  'themes.php' => 'layout',
40
  'widgets.php' => 'layout_content',
@@ -44,23 +46,27 @@ $wp_ozh_adminmenu['icon_names'] = array(
44
  'custom-background' => 'layout_edit', // Twenty Ten
45
  'custom-header' => 'layout_edit', // Twenty Ten
46
  'functions.php' => 'layout_edit', // Old themes
 
47
  /* Plugins */
48
  'plugins.php' => 'plugin',
 
49
  'plugin-install.php' => 'plugin_add',
50
  'plugin-editor.php' => 'plugin_edit',
51
- 'akismet-key-config' => 'comment_delete', // Akismet
52
  /* Users */
53
- 'options-misc.php' => 'wrench_orange',
54
  'users.php' => 'group',
55
  'user-new.php' => 'user_add',
56
  'profile.php' => 'user',
57
  'ozh_admin_menu_logout' => 'cancel',
 
58
  /* Tools */
59
  'tools.php' => 'application_lightning',
60
  'import.php' => 'door_in',
61
  'export.php' => 'door_out',
62
  'network.php' => 'world_edit',
63
- 'ms-delete-site' => 'world_delete',
 
64
  /* Settings */
65
  'options-general.php' => 'wrench',
66
  'options-writing.php' => 'page_white_wrench',
@@ -69,6 +75,20 @@ $wp_ozh_adminmenu['icon_names'] = array(
69
  'options-media.php' => 'image_options',
70
  'options-privacy.php' => 'eye',
71
  'options-permalink.php' => 'link_edit',
 
 
 
 
 
 
 
 
 
 
 
 
 
 
72
  );
73
 
74
  ?>
5
  */
6
 
7
  $wp_ozh_adminmenu['icon_names'] = array(
8
+ /* Site Admin */
9
+
 
 
 
 
 
10
  /* Dashboard */
11
  'index.php' => 'application_view_tile',
12
  'my-sites.php' => 'world',
13
  'update-core' => 'wordpress_icon',
14
  'akismet-stats-display' => 'comment_delete', // Akismet
15
+
16
  /* Posts */
17
  'edit.php' => 'pencil',
18
  'post-new.php' => 'page_white_edit',
19
+ 'edit-tags.php' => 'tag_blue_edit', // Deprecated
20
  'edit-tags.php?taxonomy=category' => 'tag_red',
21
  'edit-tags.php?taxonomy=post_tag' => 'tag_blue_edit',
22
+
23
  /* Media */
24
  'upload.php' => 'image',
25
  'media-new.php' => 'image_add',
26
+
27
  /* Links */
28
  'link-manager.php' => 'link',
29
  'link-add.php' => 'link_add',
30
+ 'edit-link-categories.php' => 'link_edit', // Deprecated
31
+ 'edit-tags.php?taxonomy=link_category' => 'link_edit',
32
+
33
  /* Pages */
34
  'edit.php?post_type=page' => 'page_edit',
35
  'post-new.php?post_type=page' => 'page_edit',
36
+
37
  /* Comments */
38
  'edit-comments.php' => 'comment',
39
+
40
  /* Appearance */
41
  'themes.php' => 'layout',
42
  'widgets.php' => 'layout_content',
46
  'custom-background' => 'layout_edit', // Twenty Ten
47
  'custom-header' => 'layout_edit', // Twenty Ten
48
  'functions.php' => 'layout_edit', // Old themes
49
+
50
  /* Plugins */
51
  'plugins.php' => 'plugin',
52
+ 'akismet-key-config' => 'comment_delete', // Akismet
53
  'plugin-install.php' => 'plugin_add',
54
  'plugin-editor.php' => 'plugin_edit',
55
+
56
  /* Users */
57
+ 'options-misc.php' => 'wrench_orange', // Deprecated
58
  'users.php' => 'group',
59
  'user-new.php' => 'user_add',
60
  'profile.php' => 'user',
61
  'ozh_admin_menu_logout' => 'cancel',
62
+
63
  /* Tools */
64
  'tools.php' => 'application_lightning',
65
  'import.php' => 'door_in',
66
  'export.php' => 'door_out',
67
  'network.php' => 'world_edit',
68
+ 'ms-delete-site' => 'world_delete', // Deprecated
69
+
70
  /* Settings */
71
  'options-general.php' => 'wrench',
72
  'options-writing.php' => 'page_white_wrench',
75
  'options-media.php' => 'image_options',
76
  'options-privacy.php' => 'eye',
77
  'options-permalink.php' => 'link_edit',
78
+
79
+ /* Network Admin, missing icons only */
80
+
81
+ /* Sites */
82
+ 'sites.php' => 'world_link',
83
+ 'site-new.php' => 'world_edit',
84
+
85
+ /* Settings */
86
+ 'settings.php' => 'wrench_orange',
87
+ 'setup.php' => 'computer_edit',
88
+
89
+ /* Update */
90
+ 'upgrade.php' => 'lightning_go',
91
+
92
  );
93
 
94
  ?>
inc/js/adminmenu.js CHANGED
@@ -36,20 +36,19 @@ jQuery(document).ready(function() {
36
  var parentwidth = parseInt( jQuery('#'+target ).css('width') );
37
  jQuery('#'+target+' ul').css('min-width', parentwidth+'px');
38
  // Now check if we need to split in columns
39
- var menulength = jQuery('#'+target+' ul li').length;
40
  if (menulength > oam_toomanypluygins) {
41
  var maxw = 0;
42
  // float every item to the left and get the biggest size
43
- jQuery('#'+target+' ul li').each(function(){
44
  var width = parseInt(jQuery(this).css('width')) || '180';
45
  maxw = Math.max( width, maxw );
46
- jQuery(this).css('float', 'left');
47
  });
48
  // Resize the whole submenu
49
- if (maxw) {
50
  var cols = parseInt(menulength / oam_toomanypluygins)+1;
51
- jQuery('#'+target+' ul li').each(function(){
52
- jQuery(this).css('width', maxw+'px');
53
  });
54
  // Give the submenu a width = (max item width)*number of columns + 5px between each column
55
  jQuery('#'+target+' ul').css('width', ( cols*maxw + (5*(cols-1)) )+'px');
36
  var parentwidth = parseInt( jQuery('#'+target ).css('width') );
37
  jQuery('#'+target+' ul').css('min-width', parentwidth+'px');
38
  // Now check if we need to split in columns
39
+ var menulength = jQuery('#'+target+' ul li.ozhmenu_sublevel').length;
40
  if (menulength > oam_toomanypluygins) {
41
  var maxw = 0;
42
  // float every item to the left and get the biggest size
43
+ jQuery('#'+target+' ul li.ozhmenu_sublevel').each(function(){
44
  var width = parseInt(jQuery(this).css('width')) || '180';
45
  maxw = Math.max( width, maxw );
 
46
  });
47
  // Resize the whole submenu
48
+ if ( maxw ) {
49
  var cols = parseInt(menulength / oam_toomanypluygins)+1;
50
+ jQuery('#'+target+' ul li.ozhmenu_sublevel').each(function(){
51
+ jQuery(this).css('width', maxw+'px').css('float', 'left');
52
  });
53
  // Give the submenu a width = (max item width)*number of columns + 5px between each column
54
  jQuery('#'+target+' ul').css('width', ( cols*maxw + (5*(cols-1)) )+'px');
inc/options.php CHANGED
@@ -267,7 +267,7 @@ function wp_ozh_adminmenu_options_page() {
267
  <li><?php echo wp_ozh_adminmenu__('you want to uninstall the plugin and leave no unnecessary entries in your database.');?></li>
268
  <li><?php echo wp_ozh_adminmenu__('you want all settings to be reverted to their default values');?></li>
269
  </ul>
270
- <p class="submit" style="border-top:0px;padding:0;"><input style="color:red" name="submit" value="<?php echo wp_ozh_adminmenu__('Reset Settings');?>" onclick="return(confirm('<?php echo js_escape(wp_ozh_adminmenu__('Really do?'));?>'))" type="submit" /></p>
271
  <p><?php echo wp_ozh_adminmenu__('There is no undo, so be very sure you want to click the button!');?></p>
272
 
273
  </form>
@@ -277,8 +277,8 @@ function wp_ozh_adminmenu_options_page() {
277
  }
278
 
279
  // Sanitize string for display: escape HTML but preserve UTF8 (or whatever)
280
- function wp_ozh_adminmenu_sanitize($string) {
281
- return stripslashes(attribute_escape($string));
282
  //return stripslashes(htmlentities($string, ENT_COMPAT, get_bloginfo('charset')));
283
  }
284
 
267
  <li><?php echo wp_ozh_adminmenu__('you want to uninstall the plugin and leave no unnecessary entries in your database.');?></li>
268
  <li><?php echo wp_ozh_adminmenu__('you want all settings to be reverted to their default values');?></li>
269
  </ul>
270
+ <p class="submit" style="border-top:0px;padding:0;"><input style="color:red" name="submit" value="<?php echo wp_ozh_adminmenu__('Reset Settings');?>" onclick="return(confirm('<?php echo esc_js(wp_ozh_adminmenu__('Really do?'));?>'))" type="submit" /></p>
271
  <p><?php echo wp_ozh_adminmenu__('There is no undo, so be very sure you want to click the button!');?></p>
272
 
273
  </form>
277
  }
278
 
279
  // Sanitize string for display: escape HTML but preserve UTF8 (or whatever)
280
+ function wp_ozh_adminmenu_sanitize( $string ) {
281
+ return stripslashes( esc_attr( $string ) );
282
  //return stripslashes(htmlentities($string, ENT_COMPAT, get_bloginfo('charset')));
283
  }
284
 
inc/translations/adminmenu-nl_NL.mo ADDED
Binary file
inc/translations/adminmenu-nl_NL.po ADDED
@@ -0,0 +1,238 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Ozh' Admin Drop Down Menu\n"
4
+ "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2009-02-20 15:33+0100\n"
6
+ "PO-Revision-Date: 2011-03-01 11:29+0100\n"
7
+ "Last-Translator: Cees van den Heuvel <cvandenheuvel@intermediad.nl>\n"
8
+ "Language-Team: <cvandenheuvel@intermediad.nl>\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Poedit-KeywordsList: wp_ozh_adminmenu__\n"
13
+ "X-Poedit-Basepath: E:\\home\\svn\\plugins\\ozh-admin-drop-down-menu\n"
14
+ "X-Poedit-Language: Dutch\n"
15
+ "X-Poedit-Country: NETHERLANDS\n"
16
+ "X-Poedit-SearchPath-0: E:\\home\\svn\\plugins\\ozh-admin-drop-down-menu\n"
17
+
18
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/core.php:348
19
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/core.php:403
20
+ msgid "updated"
21
+ msgstr "bijgewerkt"
22
+
23
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/core.php:353
24
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/core.php:408
25
+ msgid "deleted"
26
+ msgstr "verwijderd"
27
+
28
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/core.php:358
29
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/core.php:413
30
+ #, php-format
31
+ msgid "Admin Drop Down Menu settings <strong>%s</strong>"
32
+ msgstr "Admin Drop Down Menu instellingen <strong>%s</strong>"
33
+
34
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:33
35
+ msgid "Icons"
36
+ msgstr "Iconen"
37
+
38
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:34
39
+ msgid "Display menu icons"
40
+ msgstr "Toon menu iconen"
41
+
42
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:35
43
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:63
44
+ #, php-format
45
+ msgid "They're so cute (and they're from %s)"
46
+ msgstr "Heel grappig (ze komen van %s)"
47
+
48
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:40
49
+ msgid "Submenus"
50
+ msgstr "Submenus"
51
+
52
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:41
53
+ msgid "Display sub menus the regular way"
54
+ msgstr "Toon submenus op de gebruikelijke manier"
55
+
56
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:42
57
+ msgid "Some like it better when sub menus don't even need you to hover the top menu link"
58
+ msgstr "Sommige mensen geven er de voorkeur aan dat je voor submenus niet over het hoofditem hoeft te gaan"
59
+
60
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:45
61
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:123
62
+ msgid "Break Long Lists"
63
+ msgstr "Verdeel lange lijsten"
64
+
65
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:46
66
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:124
67
+ #, php-format
68
+ msgid "Break if more than %s menu entries"
69
+ msgstr "Verdeel als er meer dan %s menu opties zijn"
70
+
71
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:47
72
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:125
73
+ msgid "If a dropdown gets longer than this value, it will switch to horizontal mode so that it will hopefully fit in your screen (requires javascript)"
74
+ msgstr "Als een lijst langer wordt dan deze waarde wordt overgeschakeld naar horizontale weergave zodat het hopelijk op je scherm past (javascript vereist)"
75
+
76
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:52
77
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:128
78
+ msgid "Top Links"
79
+ msgstr "Hoofditem"
80
+
81
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:53
82
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:129
83
+ msgid "Make top links clickable"
84
+ msgstr "Maak hoofditems klikbaar"
85
+
86
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:54
87
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:130
88
+ msgid "Uncheck this option to improve compatibility with browsers that cannot handle the \"hover\" event (<em>ie</em> most handheld devices)"
89
+ msgstr "Schakel deze optie uit om de compatibiliteit met browsers te verbeteren die niet kunnen omgaan met het \"hover\" mechanisme (<em>zoals</em> de meeste portable devices)"
90
+
91
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:57
92
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:138
93
+ msgid "Give Some &hearts;"
94
+ msgstr "Deel een aantal &hearts; uit"
95
+
96
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:58
97
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:139
98
+ #, php-format
99
+ msgid "Do you like this plugin? Then <a href=\"%s\">rate it 5 Stars</a> on the official Plugin Directory!"
100
+ msgstr "Vind je de plugin nuttig? Dan <a href=\"%s\">geef hem 5 Sterren</a>op de officiele Plugin Directory!"
101
+
102
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:59
103
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:140
104
+ #, php-format
105
+ msgid "Do you <em>love</em> this plugin? Please <a href=\"%s\">blog about it</a>! Tell your readers you like it so they will discover, try and hopefully like it too&nbsp;:)"
106
+ msgstr "Vind je deze plugin <em>super</em>? Dan <a href=\"%s\">vertel er iets over op je site</a>! Vertel je bezoekers erover zodat ze hem ook ontdekken, uitproberen en hopelijk ook waarderen &nbsp;:)"
107
+
108
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:60
109
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:141
110
+ #, php-format
111
+ msgid "Are you <span id=\"totallycrazy\">crazy</span> about this plugin? <a href=\"%s\">Paypal me a beer</a>! Every donation warms my heart and motivates me to release free stuff!"
112
+ msgstr "Ben je helemaal <span id=\"totallycrazy\">weg</span> van deze plugin? <a href=\"%s\">Paypal me een biertjer</a>! Elke donatie geeft me een warm gevoel en motiveert me om meer gratis zaken beschikbaar te maken!"
113
+
114
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:81
115
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:248
116
+ msgid "Save Changes"
117
+ msgstr "Opslaan wijzigingen"
118
+
119
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:87
120
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:101
121
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:254
122
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:268
123
+ msgid "Reset Settings"
124
+ msgstr "Terugzetten instellingen"
125
+
126
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:96
127
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:263
128
+ msgid "Clicking the following button will remove all the settings for this plugin from your database. You might want to do so in the following cases:"
129
+ msgstr "Als je op de volgende knop klikt worden alle instellingen van de plugin verwijderd uit je database. Dat zou je willen doen in de volgende situaties:"
130
+
131
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:98
132
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:265
133
+ msgid "you want to uninstall the plugin and leave no unnecessary entries in your database."
134
+ msgstr "je wil de plugin deinstalleren en geen onnodige gegevens in je database achterlaten."
135
+
136
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:99
137
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:266
138
+ msgid "you want all settings to be reverted to their default values"
139
+ msgstr "je wilt alle instellingen terugzetten naar hun beginwaardes."
140
+
141
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:101
142
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:268
143
+ msgid "Really do?"
144
+ msgstr "Weet je het zeker?"
145
+
146
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/tags/2.3.4.1/inc/options.php:102
147
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:269
148
+ msgid "There is no undo, so be very sure you want to click the button!"
149
+ msgstr "Er is geen weg terug, dus zorg dat je heel zeker weet dat je op de knop wilt drukken!"
150
+
151
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:46
152
+ msgid "Icons and Colors"
153
+ msgstr "Iconen en kleuren"
154
+
155
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:51
156
+ msgid "Top Level Icons"
157
+ msgstr "Hoofditem iconen"
158
+
159
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:52
160
+ msgid "Display original menu icons in top level links"
161
+ msgstr "Toon de originele menu iconen in de hoofditems"
162
+
163
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:53
164
+ msgid "Checking this enables Compact Mode &darr;"
165
+ msgstr "Deze optie aanvinken maakt de Compacte weergave mogelijk &darr;"
166
+
167
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:56
168
+ msgid "Compact Mode"
169
+ msgstr "Compacte weergave"
170
+
171
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:57
172
+ msgid "Shrink top level links down to their icons"
173
+ msgstr "Geef de hoofditems weer als allleen iconen (geen tekst)"
174
+
175
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:58
176
+ msgid "That was a cool WordPress feature, so I stole it :)"
177
+ msgstr "Een heel fraaie Wordpress optie, dus die heb ik gestolen :)"
178
+
179
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:61
180
+ msgid "Sublevel Icons"
181
+ msgstr "Submenu iconen"
182
+
183
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:62
184
+ msgid "Display icons in drop down menus"
185
+ msgstr "Toon iconen in de dropdown menus"
186
+
187
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:66
188
+ msgid "Color Scheme"
189
+ msgstr "Kleurenschema"
190
+
191
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:67
192
+ msgid "Pick a color for your menu bar, using the color wheel or one of the presets"
193
+ msgstr "Kies een kleur voor je menu, gebruik de kleurenwaaier of een van de voorkeurinstellingen"
194
+
195
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:68
196
+ msgid "No subtle gradient, just plain color."
197
+ msgstr "Geen subtiel verloop, gewoon standaard kleuren."
198
+
199
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:110
200
+ msgid "Advanced Settings"
201
+ msgstr "Geavanceerde instellingen"
202
+
203
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:113
204
+ msgid "Minimal Mode"
205
+ msgstr "Minimale weergave"
206
+
207
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:114
208
+ msgid "Hide header"
209
+ msgstr "Verberg de kopregel"
210
+
211
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:115
212
+ msgid "Remove the whole header bar for maximum screen real estate. Note: The quick link to your blog will be added to the menu, the Logout link in the Users sub-menu."
213
+ msgstr "Verwijder de hele kopregel om maximale schermruimte mogelijk te maken. Let op: de de link naar je site wordt toegevoegd aan het menu, de link voor uitloggen aan het submenu Gebruikers."
214
+
215
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:118
216
+ msgid "Favorite Actions"
217
+ msgstr "Favoriete acties"
218
+
219
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:119
220
+ msgid "Display Favorite Actions"
221
+ msgstr "Geef Favoriete acties weer"
222
+
223
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:120
224
+ msgid "Just in case you realize you don't need this anymore with such a fast and usable menu."
225
+ msgstr "Wanneer je tot de conclusie komt dat je die met zo'n snel en bruikbaar menu niet meer nodig hebt."
226
+
227
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:133
228
+ msgid "Hide \"0\" Bubbles"
229
+ msgstr "Verberg \"0\" popup teksten"
230
+
231
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:134
232
+ msgid "Hide speech bubbles when no awaiting comments or outdated plugins"
233
+ msgstr "Verberg de popup teksten als er geen opmerkingen of bijgewerkte plugins zijn"
234
+
235
+ #: E:\home\svn\plugins\ozh-admin-drop-down-menu/trunk/inc/options.php:135
236
+ msgid "Check if those tiny \"0\" speech bubble are too distracting for your taste"
237
+ msgstr "Controleer of de kleine \"0\" popup teksten je teveel afleiden"
238
+
readme.txt CHANGED
@@ -1,7 +1,7 @@
1
  === Ozh' Admin Drop Down Menu ===
2
  Donate link: http://planetozh.com/exit/donate
3
  Tags: ozh, menu, menus, dashboard, admin, dropdown, drop down, productivity, css
4
- Requires at least: 3.0
5
  Tested up to: 9.9
6
  Stable tag: trunk
7
  Contributors: ozh
@@ -14,7 +14,7 @@ The lazy and the productive will love it : all admin links available in a neat h
14
 
15
  For documentation, examples, screenshot and a live demo, please refer to the official plugin page for [Admin Drop Down Menu](http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/ "Admin Drop Down Menu"). There is also an API for plugin coders (give your plugin its own special icon!).
16
 
17
- Current version is for WordPress 3.0+ only. For older unsupported versions, see the plugin's page.
18
 
19
  == Screenshots ==
20
 
1
  === Ozh' Admin Drop Down Menu ===
2
  Donate link: http://planetozh.com/exit/donate
3
  Tags: ozh, menu, menus, dashboard, admin, dropdown, drop down, productivity, css
4
+ Requires at least: 3.1
5
  Tested up to: 9.9
6
  Stable tag: trunk
7
  Contributors: ozh
14
 
15
  For documentation, examples, screenshot and a live demo, please refer to the official plugin page for [Admin Drop Down Menu](http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/ "Admin Drop Down Menu"). There is also an API for plugin coders (give your plugin its own special icon!).
16
 
17
+ Current version is for WordPress 3.1+ only. For older unsupported versions, see the plugin's page.
18
 
19
  == Screenshots ==
20
 
wp_ozh_adminmenu.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Ozh' Admin Drop Down Menu
4
  Plugin URI: http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/
5
  Description: All admin links available in a neat horizontal drop down menu. Saves lots of screen real estate! <strong>For WordPress 3.0+</strong>
6
- Version: 3.4.5
7
  Author: Ozh
8
  Author URI: http://ozh.org/
9
  */
@@ -100,29 +100,39 @@ Author URI: http://ozh.org/
100
  * 3.4.3: Fixed: CSS & JS now loading in compliance with admin SSL pref
101
  * 3.4.4: Updated: zh_TW (thanks Joan Wang!)
102
  * 3.4.5: Fixed: reintroduced filters removed by accident in november 2008.
 
 
 
 
 
 
 
 
103
  */
104
 
 
 
 
105
  /***** Hook things in when visiting an admin page. When viewing a blog page, nothing even loads in memory. ****/
106
- if (is_admin()) {
107
  global $wp_ozh_adminmenu;
108
  require_once(dirname(__FILE__).'/inc/core.php');
109
- add_action('admin_menu', 'wp_ozh_adminmenu_init', -1000); // Init plugin defaults or read options
110
  add_action('admin_menu', 'wp_ozh_adminmenu_add_page', -999); // Add option page
111
  add_action('admin_head', 'wp_ozh_adminmenu_head', 999); // Insert CSS & JS in <head>
112
  add_action('in_admin_footer', 'wp_ozh_adminmenu_footer'); // Add unobstrusive credits in footer
113
  add_filter('plugin_action_links_'.plugin_basename(__FILE__), 'wp_ozh_adminmenu_plugin_actions', -10); // Add Config link to plugin list
114
  add_filter('ozh_adminmenu_icon_ozh_admin_menu', 'wp_ozh_adminmenu_customicon'); // This plugin will have its own icon of course
115
- add_filter('admin_notices', 'wp_ozh_adminmenu', -9999); // Add the new admin menu right after the header area. Make sure we're first.
116
  }
117
 
118
- // Make sure it's WP 3.0+ only
119
  function wp_ozh_adminmenu_check(){
120
  global $wp_version;
121
- if ( version_compare($wp_version, '3', '<') ) {
122
  deactivate_plugins( basename(__FILE__) );
123
- wp_die("Sorry, this plugin requires WordPress 3.0 at least");
124
  }
125
  }
126
  register_activation_hook(__FILE__, 'wp_ozh_adminmenu_check');
127
 
128
- ?>
3
  Plugin Name: Ozh' Admin Drop Down Menu
4
  Plugin URI: http://planetozh.com/blog/my-projects/wordpress-admin-menu-drop-down-css/
5
  Description: All admin links available in a neat horizontal drop down menu. Saves lots of screen real estate! <strong>For WordPress 3.0+</strong>
6
+ Version: 3.5.4
7
  Author: Ozh
8
  Author URI: http://ozh.org/
9
  */
100
  * 3.4.3: Fixed: CSS & JS now loading in compliance with admin SSL pref
101
  * 3.4.4: Updated: zh_TW (thanks Joan Wang!)
102
  * 3.4.5: Fixed: reintroduced filters removed by accident in november 2008.
103
+ * 3.4.99: Updated: Quick compatibility with WP 3.1 (missing icons)
104
+ Fixed: (some?) notices when debug mode on
105
+ * 3.5: Updated: finished compat with WP 3.1 (added missing icons + proper init hooks used)
106
+ Fixed: JS bug introduced with WP 3.1 when resizing menus
107
+ * 3.5.1: Added: nl_NL (thanks Cees van den Heuvel)
108
+ * 3.5.2: Added: version constant
109
+ * 3.5.3: Removed: a console.debug might be problematic
110
+ * 3.5.4: Fixed: deprecated function calls removed
111
  */
112
 
113
+
114
+ define( 'OZH_MENU_VER', '3.5.4' );
115
+
116
  /***** Hook things in when visiting an admin page. When viewing a blog page, nothing even loads in memory. ****/
117
+ if ( is_admin() ){
118
  global $wp_ozh_adminmenu;
119
  require_once(dirname(__FILE__).'/inc/core.php');
120
+ add_action('admin_init', 'wp_ozh_adminmenu_init', -1000); // Init plugin defaults or read options
121
  add_action('admin_menu', 'wp_ozh_adminmenu_add_page', -999); // Add option page
122
  add_action('admin_head', 'wp_ozh_adminmenu_head', 999); // Insert CSS & JS in <head>
123
  add_action('in_admin_footer', 'wp_ozh_adminmenu_footer'); // Add unobstrusive credits in footer
124
  add_filter('plugin_action_links_'.plugin_basename(__FILE__), 'wp_ozh_adminmenu_plugin_actions', -10); // Add Config link to plugin list
125
  add_filter('ozh_adminmenu_icon_ozh_admin_menu', 'wp_ozh_adminmenu_customicon'); // This plugin will have its own icon of course
126
+ add_filter('all_admin_notices', 'wp_ozh_adminmenu', -9999); // Add the new admin menu right after the header area. Make sure we're first.
127
  }
128
 
129
+ // Make sure it's WP 3.1+ only
130
  function wp_ozh_adminmenu_check(){
131
  global $wp_version;
132
+ if ( version_compare($wp_version, '3.1', '<') ) {
133
  deactivate_plugins( basename(__FILE__) );
134
+ wp_die("Sorry, this plugin requires WordPress 3.1 at least");
135
  }
136
  }
137
  register_activation_hook(__FILE__, 'wp_ozh_adminmenu_check');
138