Search code examples
javascriptjqueryeventsoperaarrow-keys

Opera, jQuery - prevent notice popup on key up


I'm trying to build a selector box with search results which can be selected using the keyboard. It's not too hard to do - except when it comes to Opera which I can't prevent from popping up an own selector box (wand form settings) on key down, making it impossible to make a choice from mine.

Here's a little demo: Type something into the box and try to select from my popup with the arrow down... will work as intended in latest Chrome, for example - won't work in latest Opera.

Opera's my favorite, so I need to find a solution just to satisfiy myselve ;-)

http://jsfiddle.net/ujFvn/13/

Thanks for sharing ideas...


Solution

  • See jQuery keyup keyCode doesn't work in Opera

    Soloution: use autocomplete="off"

    <input id="test" value="" autocomplete="off" >
    

    Or if you wan't to keep it clean in JS:

    e.preventDefault();
    

    Inside your keyup function.

    Hope it helps :)