• Hey,

    I think i have correct code to display a submenu in my plugin, however I can’t seem to get it showing?

    function my_plugin_menu() {
            add_menu_page( 'Roundabout', 'Roundabout', 'manage_options', 'my-unique-identifier', 'my_roundabout_options' );
            add_submenu_page('my-unique-identifier', 'Delete Job', 'manage_job', 'delete-job', 'delete_a_job');
        }

    [Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]

    Anything im missing?

Viewing 1 replies (of 1 total)
  • you are passing in delete-job as the capability. However looking through the docs I could not see a capability called delete-job. Perhaps this is stopping WP from adding the menu correctly?

Viewing 1 replies (of 1 total)
  • The topic ‘My code for creating a submenu in plugin won't work’ is closed to new replies.