Skip to content

Instantly share code, notes, and snippets.

@Farmatique
Created August 21, 2020 12:15
Show Gist options
  • Save Farmatique/0dac4fbc12117c863c69d9d9e8cbffff to your computer and use it in GitHub Desktop.
Save Farmatique/0dac4fbc12117c863c69d9d9e8cbffff to your computer and use it in GitHub Desktop.
Get each item of menu in Wordpress
$menu_items = wp_get_nav_menu_items( 'social-menu' );
foreach( $menu_items as $item ) {
print_r($item);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment