Thank you for the help yes it worked but I fixed the code to something like this
/** Make Parent Menu Clickable */
function make_parent_menu_clickable() {
?>
<script>
(function($) {
$(window).on('load', function() {
var $wrapper = $('.jeg-elementor-kit.jkit-nav-menu');
$wrapper.find('li.menu-item-has-children > a').each(function() {
$(this).unbind();
console.log($wrapper)
$(this).on('click', function(e) {
dropdown.addClass('dropdown-open')
})
});
})
})(jQuery)
</script>
<?php
}
add_action( 'wp_footer', 'make_parent_menu_clickable' );
and it worked fine on mobile with the setting above in elementor
-
This reply was modified 2 years, 7 months ago by
bowbow7.