Using post meta in wp_nav_menu
-
Hello,
I want to display a subtitle (kicker) with each link that is generated with wp_nav_menu().
I have created a post meta called ‘kicker’ and was hoping I could do something like the following:
<?php wp_nav_menu( array('theme_location' => 'main', 'menu_class' => 'sf-menu', 'after' => get_post_meta($post->ID, "kicker", true) )); ?>
Unfortunately this doesn’t work, probably because it can’t get the ID, anyone know how I can get this working?
Thanks.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Using post meta in wp_nav_menu’ is closed to new replies.