boldlygo
Member
Posted 3 years ago #
I've recently redone my layout, and now for some reason there is an "All" option in my menu. It's driving me nuts. I can't find it anywhere in the code to get rid of it.
Website: boldlygo.org
Code:
<div id="header">
<div id="categorylist">
<ul>
<li<?php if(!is_page() ) { ?> class="current_page_item"<?php } ?>><a href="<?php bloginfo('home'); ?>">Home</a></a></li>
<?php wp_list_pages('sort_column=menu_order&depth=1&title_li='); ?>
<li<?php if(!is_category() ) { ?> class=""<?php } ?>></li>
<?php list_cats(); ?>
</ul>
Thanks!
Have you created a WP page with the title "All"? If so, try setting it to draft.
boldlygo
Member
Posted 3 years ago #
Have you created a WP page with the title "All"? If so, try setting it to draft.
Nope.
What's this line supposed to do?
<li<?php if(!is_category() ) { ?> class=""<?php } ?>></li>
Try removing it.
boldlygo
Member
Posted 3 years ago #
When I go into pages I've created three pages. The "About" page and two pages I've set to private: "Archives" and "Thank You". I can find the "Home" page in the code, and the other menu options are categories.
I don't know where "All" is coming from...
boldlygo
Member
Posted 3 years ago #
What's this line supposed to do?
<li<?php if(!is_category() ) { ?> class=""<?php } ?>>
Try removing it.
That line did nothing apparently :). It's gone now, no change.
Perhaps it's coming from elsewhere in header.php or whatever file is generating the top nav bar. Can you drop a copy of the full relevant file into the Pastebin?
boldlygo
Member
Posted 3 years ago #
Doh! It was staring me in the face! The list_cats() tag is outdated and needs to be replaced by wp_list_categories().
boldlygo
Member
Posted 3 years ago #
Thanks! Lol. That worked. I never would have gotten that.