working with wp_nav_menu (2 posts)

  1. bad.chife
    Posted 3 years ago #

    Hey, I'm having an issue working with wp_nav_menu, I'm trying to create my own Theme for WP, now i've putted that code into my functions.php file,

    function register_my_menu() {
      register_nav_menu('header-menu',__( 'Header Menu' ));
    add_action( 'init', 'register_my_menu' );

    as the guide said, and now when I'm trying to combine it into my design, the paramters I pass in the wp_nav_menu function doesn't really do anything, and I dont really understand why, I tried to play with it but it doesnt seem like something gets changed.

    wp_nav_menu( array( 'items_wrap'      => '<ul id="danny" class="danny">%3$s</ul>','theme_location' => 'header-menu' ) );

    it doesnt metter what I do, what I add as a paramter the output stays as it is, anyone has anyidea? am I missing something?


  2. Andrew Bartel
    Posted 3 years ago #

    Have you verified that Header Menu is showing up as a registered location under Appearance > Menus? Did you add an menu to that location?

Topic Closed

This topic has been closed to new replies.

About this Topic