[wp-trac] [WordPress Trac] #10708: Root level plugin admin menus not showing in Wordpress 2.8.4
WordPress Trac
wp-trac at lists.automattic.com
Tue Sep 1 00:51:22 UTC 2009
#10708: Root level plugin admin menus not showing in Wordpress 2.8.4
--------------------------+-------------------------------------------------
Reporter: tinwatchman | Owner: westi
Type: defect (bug) | Status: new
Priority: normal | Milestone: Unassigned
Component: Plugins | Version: 2.8.4
Severity: normal | Keywords:
--------------------------+-------------------------------------------------
Hello -
I'm trying to develop a plugin on an install of Wordpress 2.8.4. However,
I'm being held up by the fact that I can't seem to create root-level admin
menus.
To make sure something wasn't going wrong elsewhere in the plugin, I
created a new test plugin to isolate the problem. Here's my code:
{{{
<?php
/*
Plugin Name: Admin Menu Test
Plugin URI: http://www.jonstout.net/
Description: Attempts to create a new root level menu page in Wordpress
2.8.4
Version: 0.1
Author: Jon Stout
Author URI: http://www.jonstout.net/
*/
?>
<?php
function menutest_mypage() { ?>
<div class="wrap">
<h2>Menu Test</h2>
<p>Menu test was successful!</p>
</div>
<?php }
function menutest_add_admin_menu() {
$menutestMenuPage = add_menu_page('Menu Test','Menu
Test',1,__FILE__,'menutest_mypage');
}
add_action('admin-menu','menutest_add_admin_menu');
?>
}}}
Starting up the plugin resulted in - no new admin menu. With all other
plugins turned off, using the default Wordpress theme; on n Linux-Apache
server running PHP 5.2.8. What makes it particularly bizarre is that I
have another plugin using the same sort of code on another site / another
server using nearly the exact same code without any problems whatsoever.
I've tried a complete reinstall, complete with a new database and
everything; still no luck.
Does anyone have any idea what's going on? The only thing I can think of
at this point is that there might be a bug in the plugin API code in that
security update that happened over the weekend. Any ideas?
Thank you for your time.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/10708>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list