Forums

add_menu_page title not displaying (3 posts)

  1. dan s
    Member
    Posted 3 years ago #

    I thought this would be pretty simple, but for the life of me I don't know whats wrong.

    I'm using the following code to set up a top level menu, however I can't get the tittle to show up.

    it should show "mysite > xyz -- WordPress - Mozilla Firefox" but all I get is "mysite > -- WordPress - Mozilla Firefox" does anyone have any idea whats wrong?

    function xyzOptions() {
      echo '<p>Hello World<p>';
    }
    
    function xyzLoadMenu(){
        add_menu_page('xyz','xyz', 8, __FILE__, xyzOptions);
    }
    
    add_action('admin_menu', 'xyzLoadMenu');

    -Dan

  2. dardna
    Member
    Posted 2 years ago #

    Faced the same situation,
    this thread is surely of some interest:
    http://osdir.com/ml/wordpress-hackers/2009-02/msg00079.html.

  3. archon810
    Member
    Posted 2 years ago #

    So, for anyone who is wondering how to fix this fascinating situation for WP < 2.8 (it was fixed in 2.8), you have to create at least one submenu and then things will work. Dumb...

Topic Closed

This topic has been closed to new replies.

About this Topic