Skip to content

Commit

Permalink
Nested menus should display correctly
Browse files Browse the repository at this point in the history
There's still a display issue with a sub-item of the last item
in my menu, but the major bug is fixed.
  • Loading branch information
dgw committed Nov 15, 2010
1 parent 3970367 commit d719eca
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
<?php echo lightword_homebtn(__('Home','lightword')); ?>
<?php
if ( function_exists('wp_nav_menu') ) {
$lightword_menu = wp_nav_menu( array( 'menu'=>'lightword_top_menu', 'fallback_cb'=>'lightword_wp_list_pages', 'echo' => false, 'menu_id'=>'front_menu', 'container' => '', 'theme_location' => 'lightword_top_menu', 'link_before'=>'<span>', 'link_after'=>'</span>' ) );
$lightword_menu = str_replace(array('<ul id="front_menu" class="menu">','</ul>'), array(''), $lightword_menu);
$lightword_menu = wp_nav_menu( array( 'menu' => 'lightword_top_menu', 'fallback_cb' => 'lightword_wp_list_pages', 'echo' => false, 'menu_id' => 'front_menu', 'container' => '', 'theme_location' => 'lightword_top_menu', 'link_before' => '<span>', 'link_after' => '</span>' ) );
$lightword_menu = preg_replace( array( '/^<ul id="front_menu" class="menu">/', '/\n<\/ul>$/' ), '', $lightword_menu);
echo $lightword_menu;
}else{
echo lightword_wp_list_pages();
Expand All @@ -39,4 +39,4 @@
</div>

</div>
<div id="content">
<div id="content">

0 comments on commit d719eca

Please sign in to comment.