It's onItemSelect, not onSelectItem (the docs are wrong.) -Dan
>-----Original Message----- >From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On >Behalf Of michelem >Sent: Friday, May 09, 2008 12:11 PM >To: jQuery (English) >Subject: [jQuery] autocomplete onSelectItem > > >Hi, >I'm trying the autocomplete plugin from: >http://www.pengoworks.com/workshop/jquery/autocomplete.htm >I have a problem with the onSelectItem option that I suppose it will >be triggered when I select a value, right? >So i would like to do something when the value is selected, but It >doesn't work with my code: > ><script type='text/javascript'> > > jQuery(document).ready(function($){ > $("#searchbox").autocomplete("db.php", { > minChars:2, > maxItemsToShow:25, > cacheLength:10, > onSelectItem:function(){ > alert('Hello'); > }, > autoFill:true > }); > }); > ></script> > ><input type="text" name="myinput" id="searchbox" class="ac_input" > > >Everything works fine but the onSelectItem option seems to do nothing, >any ideas? >thank you very much > >Michele