add_menu_page Capability Not Working
-
Hi,
I am creating a plugin and I want to allow the Editors to access the plugin menu page. I set the capability to publish_pages but its not working. The option page is showing to admin user but not editor user. What have I done wrong?
function twsa_register_menu() { add_menu_page( __('Agents Stats', 'textdomain'), __('Agents Stats', 'textdomain'), 'publish_pages', 'wcas', 'tw_agents_stats_page', 'dashicons-chart-pie' ); } // create custom plugin settings menu add_action('admin_menu', 'twsa_register_menu');
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘add_menu_page Capability Not Working’ is closed to new replies.