Hampstead
Member
Posted 2 years ago #
I'm using a theme which has a link to the blog in the navigation. How do I remove it?
<ul id="nav">
<ul>
<li<?php if (is_home()){ echo " class=\"current_page_item\"";}?>><a href="<?php bloginfo('url'); ?>">Home</a></li>
<?php wp_list_categories('orderby=name&order=DESC&show_count=0&title_li=&exclude='.$featuredcategory.$comma.$singlefamcategory.$comma.$multifamcategory.$comma.$condocategory.$comma.$mfgcategory); ?>
<?php wp_list_pages('sort_column=menu_order&title_li='); ?>
</ul>
</ul>
you want to remove a link to 'Blog'? Or to 'Home'?
Removing this:
<a href="<?php bloginfo('url'); ?>">Home</a>
would get rid of the home link. If its to something called 'blog' thats not in the code, so it would be a page you made or soemthing, which could be excluded....but I wanna verify what you are asking first!
Hampstead
Member
Posted 2 years ago #
Keep the homepage link, but there is a link to the blog category. If I remove the blog category, the theme breaks.
so blog is a category? Looks like you'd need to exclude it then in the long complicated wp_list_categories line
http://codex.wordpress.org/Good_Navigation_Links#Categories
your exclude list in there is already pretty complicated, not sure the best way to add the blog category tho.....
Hampstead
Member
Posted 2 years ago #
Yes it's a category. I want to exclude all categories except one.
I'll keep digging.
Hampstead
Member
Posted 2 years ago #
Hampstead
Member
Posted 2 years ago #