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

I am working on a 'from scratch' theme which has a simple wp_nav_menu call;

 wp_nav_menu(Array('menu_class' => 'nav', 'container' => FALSE)); 

On standard posts, archives and pages this produces the HTML I am expecting.

I have an issue when the active page/current menu item is a custom post type archive/single, wp_nav_menu generates the expected current-menu-item class for the active menu item, however it also generates a *current_page_parent* for the Blog link. The blog simply cannot be a page parent for a custom post type archive/single.

Some related images to help: http://bloke.org/uncategorized/untitled-post/

So how or why is this happening?

share|improve this question
Your link 404s. – vancoder Jun 28 '13 at 18:10
This appears to be the same issue, but the solution may be a hack: wordpress.org/support/topic/… – vancoder Jun 28 '13 at 18:12

From look at core this is coming from this:

// back-compat with wp_page_menu: add "current_page_parent" to static home page link for any non-page query
if ( ! empty( $home_page_id ) && 'post_type' == $menu_item->type && empty( $wp_query->is_page ) && $home_page_id == $menu_item->object_id )
    $classes[] = 'current_page_parent';

It seems to be some legacy thing, I would just ignore it if you don't actually need it for some reason.

share|improve this answer
Looks like vancoder's solution works. – Kieran 'Kizbo' Barnes Jul 2 '13 at 12:59

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.