Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Form Submission issue after hitting Enter Key
This topic contains 3 replies, has 2 voices, and was last updated by Ernest Marcinko 2 weeks, 2 days ago.
- AuthorPosts
- March 15, 2023 at 10:36 am #41764
Hi there,
I have set up your plugin to my Staging and Live server and the issue is happening on both of the sites. So, I have provided you with a temporary login URL of the staging site (it will not require Username and Password).
The issue happening with the MAC platform’s Safari and Chrome browsers, when fillup the search form and hitting the ENTER key from the keyboard. It took me to the home page instead of the search page.
It’s working properly when I fill up the form and click on the Search button. So, the issue is only when I am hitting ENTER key from Safari and Chrome in the MAC platform. You can get the Search form below URL:
https://qa.guru.com/help/employer/
https://qa.guru.com/help/freelancer/I myself debugged the issue and found that submit button is placed outside the FORM see the attached screenshot https://prnt.sc/4LJIy3Z7mRNX. This is why the form is not submitted on when I hit Enter button.
Can you please take a look and resolve it.
March 15, 2023 at 1:27 pm #41780Hi,
You have a custom code added to the page, which casuses the issue:
$(document).on('keypress', '.wpdreams_asp_sc.asp_main_container form input[type="search"]', function(event) { if(event.which == 13) { if(!$(this).val()) return false; window.location.href = '/?s='+ $(this).val() + '&type=' + type; } });
It is located in
Best,wp-content/themes/Guru/js/script.js
file.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
March 15, 2023 at 2:28 pm #41792Thanks for the help. It’s working properly,
March 16, 2023 at 11:31 am #41803You cannot access this content. Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
- AuthorPosts
You must be logged in to reply to this topic.