We've expanded our news coverage and improved our search! Visit news.oreilly.com for the latest or search for all things across O'Reilly!
advertisement

Article:
  Cooking with JavaScript & DHTML
Subject:   Select Type-Ahead
Date:   2004-04-19 23:10:01
From:   dannyg1
Response to: Select Type-Ahead

You need to add one line of code that short-circuits the Tab character. After the line in the typeAhead() function that reads var charCode = evt.keyCode;, add the following line:

if (charCode == 9) { return true; }

That appears to do the trick.