Can menu items get custom field values from the post they link to?
-
WordPress’ menu system loads objects called $item for every menu link. The $item object contains the title from the post or page it links to. I’m wondering if I can make the $item contain other stuff, like a value from a custom field on the post?
I realize that I can enter a value in the ‘description’ field on the link, when I edit the menu. But it would save much repetitive editing if I could enter a value on custom field on the page or post, and have that value display on the menu?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Can menu items get custom field values from the post they link to?’ is closed to new replies.