Context : I made a website with a search function but I wanted to block the display of the code when hitting enter key. This is a basic function to block the submit when .yith-s is called ( my search function )
I made this script :
jQuery(document).ready(function($) {
var form = $('form');
form.on('submit', function () {
if (form.find('.yith-s').length > 0) {
return false;
}
});
});
And it works very well with chrome and firefox.
However, this does not work with IE.
Do you know how i can make it work with IE ( 9 would be awesome ) ?