Add hooks to enable access to pages in the admin when the menu layout has been changed by plugin
|Reported by:||mikeschinkel||Owned by:||westi|
This patch and ticket is a follow on to tickets #16048 and #16050 and indirectly related to this discussion on hackers: http://lists.automattic.com/pipermail/wp-hackers/2011-January/037129.html
This patch simply adds the following hooks, all within /wp-admin/includes/plugin.php.
The patch does not attempt to unravel the many early exits of the various functions instead it simply redundantly adds the hooks at each exit point. As such it's backward compatibility can be reviewed simply by viewing the code.
The use-case for this patch is when the menus are not exactly in the format expected by WordPress (but instead desired by the client) it can sometimes take hours of trial and error to get the permissions to allow users access to the menus they should be allowed access to.
For example, if the first submenu page for a menu page is removed from the menu, even when it makes logical sense to the user WordPress currently does not allow that menu option to be viewed. These hooks would give plugin developers the ability to modify the menus and still enable users access to the pages they need access to.