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 know that WP3 offers wp_nav_menu and description field but I was wondering if it is possible to alter wp_page_menu to echo desired meta key value next to the page link in format that is adjustable.

Hope my question is clear.


share|improve this question
up vote 1 down vote accepted

There is no easy way to alter the vale of each li in the wp_page_menu but there is a way to do it without creating your own function or custom walker using the_title filter hook.

so create your function , something like this:

function custom_menu_title($title,$post_id){
  return $title . ' ' . get_post_meta($post_id,'meta_key',true);

and you hook it before you call wp_page_menu and remove it right after so:

share|improve this answer
Will check the solution and answer shortly after. Thanks man. – daniel.tosaba Aug 20 '12 at 20:47
How would you display desired meta key value using custom Walker class? No need for whole function just part where you add value to the variable. Thanks – daniel.tosaba Aug 24 '12 at 4:57

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.