Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi,

    You can add this code to the file functions.php in the child theme folder or use the plugin Code Snippets to implement.

    
    add_action( 'wp_footer', function() {
    	?>
    	<script type="text/javascript">
    		jQuery(document).ready(function($) {
    			$('ul.nav-menu > li.menu-item-has-children > a').on('click', function() {
    				$(this).closest('.menu-item').find('.nav-toggle-icon').trigger('click');
    			});
    		});
    	</script>
    	<?php
    } );

    it will help you open the sub-menu when clicking to the menu item, not only the arrow down.

    Regards.

    Thread Starter cjuni

    (@cjuni)

    Hi,
    When I click it, it also opens all the submenus within the submenu that was clicked.
    I made a video for you to understand better.
    https://youtu.be/9Q06Cem-yO4

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Toggle button’ is closed to new replies.