poland88 Posted August 27, 2010 Share Posted August 27, 2010 Hi,How to do it so it was as in e.g. http://www.google.com/ when I type something I can see appearing possible matches, but when I press enter only what I wrote is send, NOT THE FIRST MATCH (as it is in prestashop). How to change it?Thank you in advance Link to comment Share on other sites More sharing options...
phrasespot Posted August 28, 2010 Share Posted August 28, 2010 Hi,How to do it so it was as in e.g. http://www.google.com/ when I type something I can see appearing possible matches, but when I press enter only what I wrote is send, NOT THE FIRST MATCH (as it is in prestashop). How to change it?Thank you in advance It is what you typed is sent. Visit demo, click in search box and start typing in "shu", briefly pause and let the suggestions appearer, ignore and press enter. Results for shu will be displayed. When typing do not touch your mouse or any down key, causing one of the suggestions to be selected/highlighted (dark background) as in third image attached Link to comment Share on other sites More sharing options...
poland88 Posted August 29, 2010 Author Share Posted August 29, 2010 Thank you, you are right.So there is another bug in my shop. Link to comment Share on other sites More sharing options...
poland88 Posted August 29, 2010 Author Share Posted August 29, 2010 I overwrote all java (js/jquery/) files and still it is the same. Do you have any idea why?Here's the link:http://sklep.komtek.pl Link to comment Share on other sites More sharing options...
phrasespot Posted August 29, 2010 Share Posted August 29, 2010 I overwrote all java (js/jquery/) files and still it is the same. Do you have any idea why?Here's the link:http://sklep.komtek.pl It is not a bug but setting in JQuery. Find the file http://sklep.komtek.pl/js/jquery/jquery.autocomplete.jsFind the section at the beginning:$.fn.extend({ autocomplete: function(urlOrData, options) { var isUrl = typeof urlOrData == "string"; options = $.extend({}, $.Autocompleter.defaults, { url: isUrl ? urlOrData : null, data: isUrl ? null : urlOrData, delay: isUrl ? $.Autocompleter.defaults.delay : 10, max: options && !options.scroll ? 10 : 150 }, options); replace it with $.fn.extend({ autocomplete: function(urlOrData, options) { var isUrl = typeof urlOrData == "string"; options = $.extend({}, $.Autocompleter.defaults, { url: isUrl ? urlOrData : null, data: isUrl ? null : urlOrData, delay: isUrl ? $.Autocompleter.defaults.delay : 10, max: options && !options.scroll ? 10 : 150, selectFirst: false }, options); There are two changes: adding a comma to the end of line starting max:... and inserting the line selectFirst: falseMore info about autocomplete options are here Link to comment Share on other sites More sharing options...
poland88 Posted August 29, 2010 Author Share Posted August 29, 2010 THANK YOU !!! Link to comment Share on other sites More sharing options...
rocky Posted August 30, 2010 Share Posted August 30, 2010 Please edit your first post and add [sOLVED] to the front of the title. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now