I am using the following code for my navigation structure. Currently it shows a home link in the navigation. Why does this show? and how would I get rid of it by changing this code.

<?php wp_nav_menu( array( 'container_class' => 'menu-header', 'theme_location'=> 'primary' ) ); ?>

1 Answer 1


it shows the home link cause you don't have anything set yet...

go to your functions.php and add this code

 add_theme_support( 'menus' );
  if ( function_exists( 'register_nav_menus' ) ) {
          'header_menu' => 'Header Menu'



Go to Apparence and then get into Menu option... Create a menu set the pages/links/categories or whatever you want on it. Make sure you set the menu you just created in the dropdown list you have on top left in that panel. That should be enough to call the menu you want where you set the code you have.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.