Why show list of pages when there is no primary menu?
-
Using version 2.0.10 It looks like there is a test for a primacy menu and when there is no primary menu show a list of pages instead. I have a non-primary sidebar menu that I want to use as a widget so I can have custom HTML above it. After an unknown update, I see a list of pages above my two sidebar widgets. What was the rationale for this change? I’ve manually changed the code as follows to fix the issue for my approach so that I have a widget above the menu:
Lines 78–94:
<ul class="site-nav reset-list-style" id="main-menu" role="navigation"> <?php if ( has_nav_menu( 'primary-menu' ) ) { wp_nav_menu( array( 'container' => '', 'items_wrap' => '%3$s', 'theme_location' => 'primary-menu', ) ); } else { // Removed by bbogart //wp_list_pages( array( // 'container' => '', // 'title_li' => '', //) ); } ?> </ul>
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Why show list of pages when there is no primary menu?’ is closed to new replies.