Make WordPress Core

Opened 12 years ago

Last modified 5 years ago

#20325 new defect (bug)

Menu item parent classes for page_for_posts (home.php) not properly set on single.php

Reported by: ptietz's profile ptietz Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Menus Keywords: needs-patch
Focuses: Cc:


If one has set page_for_posts (Settings => Read), on single.php wp_nav_menu() will set current_page_parent for the accordant menu item, but it will not set any parent or ancestor classes for its parent menu items as expected. [tested with 3.3.1]

Change History (4)

#1 @ptietz
12 years ago

  • Cc ptietz@… added

#2 @drumba
11 years ago

Same time the home menu entry gets the current-menu-item class.

#3 @schlimpf
10 years ago

Any updates on this?
I am experiencing the same error. Is this behavior intended?
The same error occurs when being in a category

As far as I can tell, the error does not occur with custom post types.

Last edited 10 years ago by schlimpf (previous) (diff)

#4 @chriscct7
8 years ago

The problem seems to be in _wp_menu_item_classes_by_context

Note: See TracTickets for help on using tickets.