Hi folks
I'm wondering how keep the active class in the main nav (wp_page_menu) when a single post is viewed?
Compare http://whoshouldicheerfor.com/2010/05/the-first-post/
with
http://whoshouldicheerfor.com/blog/
For example.
Many thanks
Hi folks
I'm wondering how keep the active class in the main nav (wp_page_menu) when a single post is viewed?
Compare http://whoshouldicheerfor.com/2010/05/the-first-post/
with
http://whoshouldicheerfor.com/blog/
For example.
Many thanks
"Blog" in the first post is in class "current_page_item" while in the "blog" page in is in class "current_page_parent". All is well.
You need to modify either style.css or header.php.
style.css would be better place for that.
Something like this ("not tested", be sure):
div#navigation div.menu li.current_page_parent {
/* copy something from definitions for li.current_page_item */
}
HTH,
/dor
Brilliant, that did it. Thank you very much.
This topic has been closed to new replies.