Skip to main content

wordpress add_menu failing silently - cannot debug

I am a wordpress beginnering and I just installed the wordpress boilerplate plugin to start development. I am trying to add a menu item to the left hand menu and it doesn't work. I doesn't give me an error and I enabled debugging within wordpress. Here's the function call code:

class Tdr_Hp_Activator {

    /**
     * Short Description. (use period)
     *
     * Long Description.
     *
     * @since    1.0.0
     */
    public static function activate() {
        add_menu_page(
            "The Drew Report",
            "The Drew Report",
            "administrator",
            "/tdr-hp",
            "show_config_page",
            "",
            "1"
        );
    }

}

I stepped through the code so I know it's being called. Any ideas why it would simply faiil silently?



source https://stackoverflow.com/questions/68154302/wordpress-add-menu-failing-silently-cannot-debug

Comments