Mayfoo Posted September 21, 2021 Share Posted September 21, 2021 Hi, I am creating a multilingual site. In which I had created 2 blogs with different languages. I am using a search bar for the blog posts. I would like to disable the search result page redirection after hit "Enter" key. So I don't have to inject more code to make it looks multilingual. Is there : 1) A way to stop redirect to search result page after hit "Enter" key? 2) I had try to disable "Enter" with code injection in the blog page. The if-else statement is working as expected, but "Enter" key is still working. Where I did wrong? $(document).ready(function() { $('.sqs-block-search').on('keypress keydown keyup', function(e){ if(e.keyCode == 13) { e.preventDefault(); } }); }); 3) Is there a way to inject slug (e.g. /en ) in the URL of search result page, so it can be multilingual? Many thanks. Link to comment
tuanphan Posted September 24, 2021 Share Posted September 24, 2021 Hi, Can you share link to your site? We can check easier Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment