Well, that wasn't a good change to that function - just did it on the fly while typing up that post - but when I made the change to the actual JavaScript and realized my mistakes, it did not help. Part of the problem was that when I originally inspected event, it was not showing the event that was passed, but must have been showing the event object that's part of - what? - the DOM in IE? Anyway, changing it to myevent and then inspecting myevent reveals a different object structure and it does not have a target property. So there is something a little more complex here. Running Jörn's sample page reveals that it does work (I don't get the error I'm getting on my page), so perhaps I've taken out some code that is important (I cut out code that related to input controls on his page that I was not interested in and changed the names in his code to match the names in my code). Perhaps I've cut out something pertinent that did not seem pertinent.
On Jul 14, 11:48 am, AtlantaGeek <[EMAIL PROTECTED]> wrote: > Using Jörn Zaefferer' AutoCompleter > athttp://bassistance.de/jquery-plugins/jquery-plugin-autocomplete > > I'm getting an error in the function below. The error is at line 553, > the error is "object required", this file is jquery.autocompleter.js. > This is occurring under IE 7 and it happens when I move the mouse > cursor over the drop down that is built to display the choices the > user can select. It does not seem to happen in Firefox. > > The line where the error occurs is the WHILE line. When looking at > this I can see that the line above it should get a reference called > element to event.target. However, if I inspect element, it reports as > null. If I inspect event.target, it reports as an object that I can > then expand and see the tagName property (which is "UL" in this case). > > function target(event) { > var element = event.target; > while(element.tagName != "LI") > element = element.parentNode; > return element; > > I'll have to try changing the function to: > > function target(event) { > // var element = event.target; > while(event.target.tagName != "LI") > element = event.target.parentNode; > return element; > > Perhaps not the best solution, but I'll defer to Jörn for that.