• Resolved codex22

    (@codex22)


    Hello members,

    I tried to add a multiple navigation to my theme. Therefore I used the following code in functions.php :
    ` if (function_exists(‘register_nav_menus’)) {
    register_nav_menus(array( ‘primary’ => ‘Main Navigation’,
    ‘secondary’ => ‘Social Navigation’));
    }`
    and in my theme index.php I used the following code:

    `<?php wp_nav_menu( array ( ‘container_class’ => ‘main-nav’, ‘container’ => ‘nav’)); ?>

    <?php wp_nav_menu( array ( ‘container_id’ => ‘social’, ‘container_class’ =>’right’, ‘container’ => ‘div’, ‘menu_class’ => ‘social-nav’)); ?>`

    The Problem is, wordpress is displaying the the main navigations twice. You can view the outcome here: https://ammantempel.net/ta/

    Actually the main navigation should be on the leftside of the navbar and the social navigation (facebook, twitter, youtube…) on the right side. Please help! Thanks for your answers!

  • The topic ‘Problem with multiple navigation menus’ is closed to new replies.