WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

my question is...

I have 2 pages & 2 subpages in each page. like:







& my Menu is Page1 page2

Now if i select subpage1(from page1) means the page1 need to active and highlight the menu. if i select subpage1(from page2) means it need to highlight page2 and page2 menu in active.

how to do this? please help me to get rid of this problem.i need to implement in my wordpress website.

share|improve this question
up vote 4 down vote accepted

To highlight page 1 and page 2 use current-menu-parent class

share|improve this answer

It'll be done with CSS and an active class. Check the coding on the front end to see what wordpress has added for active page. On one setup we have the class menu-item and current_page_item is added so you could style those.

share|improve this answer

Your Answer


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.