Support » Fixing WordPress » Please help plugin Error on top level menu dashboard

  • Hello, I’m new to plugin development. I was reading Wrox Professional Professional Plugin Development. The problem is when I try to do a menu using this code.

    add_action( ‘admin_menu’, ‘boj_menuexample_create_menu’ );
    function boj_menuexample_create_menu() {
    //create custom top-level menu
    add_menu_page( ‘My Plugin Settings Page’, ‘Menu Example Settings’,
    ‘manage_options’, __FILE__, ‘boj_menuexample_settings_page’);

    and when I try to access the menu I get the following Error msg;

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘boj_menuexample_settings_page’ not found or invalid function name in C:\xampp\htdocs\wordpress\wp-includes\plugin.php on line 405

    Like I said I’m still new to this, so any help on what I should do would be appreciated.

  • The topic ‘Please help plugin Error on top level menu dashboard’ is closed to new replies.