Skip to content

Instantly share code, notes, and snippets.

@nguyenit67
Last active June 1, 2021 07:46
Show Gist options
  • Save nguyenit67/4aa8b61560862b8110a16e26d517d471 to your computer and use it in GitHub Desktop.
Save nguyenit67/4aa8b61560862b8110a16e26d517d471 to your computer and use it in GitHub Desktop.
Custom Menu In WordPress
<?php register_nav_menus( [ 'primary' => __( 'Primary Menu' ) ] ); ?>
<?php $args = [ 'theme_location' => 'primary' ]; ?>
<?php wp_nav_menu( $args ) ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment