Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › problem with search in mobile › Reply To: problem with search in mobile
February 4, 2021 at 3:52 pm
#31442
Keymaster
Hi,
Because both the menu plugins work individually, these features have to be custom coded. I might be able to recommend something though. Try adding this custom code to the functions.php in your theme/child theme directory. Before editing, please make sure to have a full site back-up just in case!
add_action('wp_footer', 'asp_menu_input_focus');
function asp_menu_input_focus() {
?>
<script>
jQuery(function($){
var t;
$('.elementor-menu-toggle').on('touchend', function(){
if (!$(this).hasClass('elementor-active')) {
clearTimeout(t);
t = setTimeout(function(){
$('.elementor-nav-menu--dropdown .proinput input.orig').get(0).focus();
console.log('sup');
}, 500);
}
});
});
</script>
<?php
}
-
This reply was modified 5 years, 4 months ago by
Ernest Marcinko.