I'm wondering if anyone is able to change the menu items on elegant grunge from pages to being able to show categories. I'm kinda new to this whole "CSS" thing, so an easier fix would be better.
Thanks.
I'm wondering if anyone is able to change the menu items on elegant grunge from pages to being able to show categories. I'm kinda new to this whole "CSS" thing, so an easier fix would be better.
Thanks.
In your header.php, find <?php wp_list_pages(); ?> and replace it with <?php wp_list_categories(); ?>. If your wp_list_pages tag is inside a <ul>, use the following: <?php wp_list_categories('title_li='); ?>
Hey Micah!
Thanks so much for the help. I've done what you said to do, but for some reason it's making the categories look all weird at the top.
You can view my site: http://www.mattmanes.com
Any more advice?
Could you copy-and-paste your header.php to http://wordpress.pastebin.ca so I can have a look?
Thanks man I figured it out. Just messed with the CSS.style sheet.
Thanks for all your help!
No problem. One thing I noticed, you should change the following code:
<div id="menu">
<ul>
<li class="page_item <?php if ( is_home() ) { ?>current_page_item<?php } ?>"><a href="<?php bloginfo('url'); ?>"><?php _e('Home.', 'elegant-grunge') ?></a></li>
<li class="page_item <?php wp_list_categories('title_li='); ?></li>
</ul>
<div class="clear"></div>
</div>
To
<div id="menu">
<ul class="nav">
<li class="page_item <?php if ( is_home() ) { ?>current_page_item<?php } ?>"><a href="<?php bloginfo('url'); ?>"><?php _e('Home.', 'elegant-grunge') ?></a></li>
<?php wp_list_categories('title_li='); ?>
</ul>
<div class="clear"></div>
</div>
Since wp_list_categories makes each page an li automatically, there's no need to encase it in an li. In your css, you can use .nav li to style your menu links.
This topic has been closed to new replies.