- 1. The folder used by the theme is in the theme folder corresponding to wp-content/themes/
- There is -----functions.php in the theme (the functions used by the theme are mainly in this), in this Add the following code to the file:
- register_nav_menus(array('header-menu' => __( 'Navigation custom menu' ),));//That is, register the navigation menu
- 2, in the header in the theme folder used. php file, put the original
- blog
- Comment out, replace
- with
- 'header-menu' )); ?>Code
- 3, in Set up in the background menu
- Create a new menu -> The options on the right can be added to the menu -> Theme location selection to use the navigation menu name
-
- Remember to save every step!
Copy code
|