This post describes briefly an implementation of Scriptaculous’ Ajax.Autocompleter class.
It uses an AJAX request using a Page element for an @DBLookup I believe first mentioned at Lotusphere 2007 by Jack Rattcliff and later (?) by Jake Howlett in his http://www.codestore.net/store.nsf/unid/BLOG-20060221 and perfectionized (?) by my collegue Tomas.
Scriptaculous autocompleter needs an unordered list in return. For instance this list might be returned after the user typed the letter “y”:
The demo allows you to fill in multiple fields after clicking on one of the presented suggestions by splitting the responseText:
In demo-mode it would look something like this:
For downloading a working example click here.