skip to Main Content

Add Content Above Mobile Toggle Menu

add_action( 'wp_footer', function() { ?>

	
		( function( $ ) {
			'use strict';
			$( window ).on( 'load', function() {
				var $nav = $( '.mobile-toggle-nav' );
				if ( $nav.length ) {
					$nav.prepend( '<div class="my-custom-toggle-nav-content container">Your custom html code here.</div>' );
				}
			} );
		} ( jQuery ) );
	

<?php }, PHP_INT_MAX );
All PHP snippets should be added via child theme's functions.php file or via the Code Snippets Plugin (or alternative plugin)
Back To Top