Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.
==================================
Home Contact About
==================================

For example, The menu should looks like

==================================
Home Contact About
     -------
==================================

when the URL is http://loaclhost/contact/XXXXXXXX, the same as other.

How to do this? It seems can use nav_menu_css_class by add_filter, but the key is how to judgment the current menu is contact (or other)?

share|improve this question
    
I have found the perfect solution. If anybody has the same issue, please go to rarescosma.com/2010/11/… –  Cynial Jul 25 '11 at 9:55
add comment

1 Answer 1

If you're using WordPress custom menus ( and you should when you're dealing with menus ), it adds class current-menu-item for page that is currently being viewed.

share|improve this answer
    
Thanks answer. I just found a perfect solution about it. For sharing. rarescosma.com/2010/11/… –  Cynial Jul 25 '11 at 9:54
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.