I’ve noticed a strange comportment of WP 2.7.1.
I have created a user Role by using the great “Role Manager” plugin (http://www.im-web-gefunden.de/wordpress-plugins/role-manager/).
I have named it “Webmaster” and give it the needed capabilities. I gave it a user_level of 8.
In my plugin i have a variable $jal_admin_user_level whose the value is equal to 2, i call the add_management_page like this :
add_management_page('Shoutbox Management', 'Live Shoutbox', $jal_admin_user_level, "wordspew_admin", 'jal_shoutbox_admin');
By the way, normally, everyone who have a level equal or up to 2 should be able to administrate the plugin. It’s true (and it works) for natives roles (author, editor, administrator) but not for the created one.
My created role level is 8 but is considered to be inferior to 2. I can’t access to the administration page of the plugin.
The only way for doing it to work is to define my variable to 8 (in fact equal to the manually defined user level), then it will work…
Any idea ?
- The topic ‘Possible bug in add_management_page’ is closed to new replies.