Home › Forums › Support › Different mobile menu? › Reply To: Different mobile menu?
April 3, 2016 at 11:33 am
#183877
Tom
Lead Developer
Lead Developer
The mobile menu should act the same regardless of slideout vs regular. If your menu item has # as the URL, you should be able to tap the entire item to initiate the dropdown. This is a feature in the latest version.
To create a new theme location for the mobile header, you need to do something like this:
add_action( 'init', 'generate_register_mobile_menu' );
function generate_register_mobile_menu() {
register_nav_menu( 'mobile-menu',__( 'Mobile Menu' ) );
}
Then you need to add this:
add_filter( 'generate_mobile_header_theme_location', 'generate_change_mobile_header_menu' );
function generate_change_mobile_header_menu()
{
return 'mobile-menu';
}
Adding PHP: https://generatepress.com/knowledgebase/adding-php-functions/
- This reply was modified 8 years, 5 months ago by Tom.