Snippets: Conditionally Select Mobile Menu Style

 * Example function to change the mobile menu style
 * Available styles: full_screen, sidr, toggle, disabled
 * @see framework/classes/global-object.php
function myprefix_change_mobile_menu_style( $style ) {

	// Disable mobile menu on homepage
	if ( is_front_page() ) {
		$style = 'disabled';

	// Return style
	return $style;
add_filter( 'wpex_mobile_menu_style', 'myprefix_change_mobile_menu_style' );

Snippet Type: PHP

Posted Under: Mobile

All PHP snippets should be added via a child theme's functions.php file or via the Code Snippets Plugin (or alternative plugin)