So I have a custom menu and I'm using wp_nav_menu() to get all items. But I also want to get some of the custom fields of each page that is on the menu and that requires the post/page IDs. Any idea how to get them?
So I have a custom menu and I'm using wp_nav_menu() to get all items. But I also want to get some of the custom fields of each page that is on the menu and that requires the post/page IDs. Any idea how to get them?
Use a custom walker (http://www.kriesi.at/archives/improve-your-wordpress-navigation-menu-output) and then you want the $item->object_id value as the ID of the actual item linked.
I am still struggling with how to find this for a custom link. Or, how to determine ID by slug or URL when it is a custom post type or similar item.
This topic has been closed to new replies.