Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • sorry, i skipped a pretty critical step! also have to add to functions.php to make a new function for each alternate navigation you will be using. like this:

    function blogmenu(){
    		if (theme_get_option('general','enable_nav_menu') && has_nav_menu( 'second-menu' ) ) {
    			wp_nav_menu( array(
    				'theme_location' => 'second-menu',
    				'container' => 'nav',
    				'container_id' => 'navigation',
    				'container_class' => 'jqueryslidemenu',
    				'fallback_cb' => '',
    				'walker' => new Theme_Walker_Nav_Menu
    			));
    		}
    	}

    the header call should look something like:

    if (is_page_template(‘template_blog.php’)){
    echo theme_generator('blogmenu');
    }
    elseif (is_page_template('template_fullwidth.php')){
    echo theme_generator('fullwidthmenu');
    }
    else {
    echo theme_generator('menu');
    }

    i have a slightly different suggestion for this problem for others who are encountering it. i spent 3+ full days trying to figure out how to solve this issue in a million complicated ways, but this worked like a charm with almost no editing code.

    once you have registered the multiple menus and created your page templates needing specific navigation, you can modify the call in header.php (if that is where nav is called from) to be conditional based on is_page_template(‘nameyourtemplate.php’).

    my world brightened when i did this. i hope someone else finds it useful.

Viewing 2 replies - 1 through 2 (of 2 total)