WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#15522 closed defect (bug) (invalid)

register_nav_menus not working

Reported by: christian_gnoth Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.0.1
Component: General Keywords:
Focuses: Cc:

Description

I am using in my theme:

  if ( function_exists( 'register_nav_menus' ) ) 
  {
    register_nav_menus( 
            array( 
                'header-menu' => 'Header Menu', 
                'extra-menu' => 'Extra Menu'
                 )
    );
  }

this two locations are not displayed in the wp admin menu srea.
there is no locations box at all - also no option to activate/deactivate it.

Change History (10)

comment:1 @nacin5 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Trac is not your personal support forum.

comment:2 @nacin5 years ago

You won't see the locations box until you create a menu.

comment:3 @westi5 years ago

And you need to ensure that you call the function on a relevant hook not just at inclusion time.

comment:4 @christian_gnoth5 years ago

  • Resolution invalid deleted
  • Status changed from closed to reopened

i called the register nav menus function on different places of my function.php file:

in the add_action('init') method,
in the functions.php file without a wrapping function,
in the add_action('after_theme_setup') method

but it does not appear in the wp admin menus page.

I can print it with wp_nav_menu() - but as it does not appear in the admin panel I can not configure it.

comment:5 @nacin5 years ago

  • Resolution set to invalid
  • Status changed from reopened to closed

comment:6 @christian_gnoth5 years ago

  • Resolution invalid deleted
  • Status changed from closed to reopened

in the forum I have already posted this subject and got a lot of answers, but no solution for this problem.

I upgraded my blog from wp_mu to wp 3.0 and then to 3.0.1, but this menu locations I never saw.

comment:7 @nacin5 years ago

  • Resolution set to invalid
  • Status changed from reopened to closed

If you'd like to link me to the support thread, I can take a look. But we're not continuing this here. I've been pretty clear:

http://core.trac.wordpress.org/ticket/15522#comment:1

http://core.trac.wordpress.org/ticket/15522#comment:5

This is an ongoing pattern:
http://core.trac.wordpress.org/query?status=closed&group=resolution&reporter=~christian_gnoth&order=priority&col=id&col=summary&col=status&col=type&col=priority&col=milestone&col=component

Please stop using tickets for support questions. We're not answering them anymore.

comment:8 @christian_gnoth5 years ago

indeed all the other problems could have been solved by the support forums, but mostly I did not got an answer/respond to my questions.

here the forum thread to this problem:

http://wordpress.org/support/topic/register_nav_menu?replies=15

comment:9 @christian_gnoth5 years ago

  • Resolution invalid deleted
  • Status changed from closed to reopened

can you please take a look at this thread??? if i do not get any help from the forum and there is no solution I can only open the problems as bugs.
I have other threads in the forums too to which I do not get help and answers....

As I am developing themes and plugins for wordpress I need some support if functions are not working as expected or described in the documentation. (indeed most of this closed tickets are misunderstanding of the docs from my side).

comment:10 @nacin5 years ago

  • Resolution set to invalid
  • Status changed from reopened to closed

can you please take a look at this thread???

I will consider it. But in order for that to happen,

if i do not get any help from the forum and there is no solution I can only open the problems as bugs.

Then you need to stop doing this. End of discussion.

Note: See TracTickets for help on using tickets.