M
Mark Smith
Hi,
I'm looking for a way to implement an autocomplete field on some of my
forms.
I need both ajax support (for larger lists) and also a way to pass in
json arrays for smaller lists.
The best I have found so far is this one:
http://www.pengoworks.com/workshop/jquery/autocomplete.htm
(I know, jQuery - yuck!)
The problem with this one (and others) is that the rendering breaks
when any of the strings contain html entity encoded characters. This
is because the dropdown list is html, but the text box value is raw
text. Fixing the code myself to reconcile the two looks like it will
become very messy.
If anyone could recommend a way to do this properly. (Either a plugin
for an existing framework or a tried and tested pattern for
implementing autocomplete in pure JS would be greatly appreciated)
Thanks
I'm looking for a way to implement an autocomplete field on some of my
forms.
I need both ajax support (for larger lists) and also a way to pass in
json arrays for smaller lists.
The best I have found so far is this one:
http://www.pengoworks.com/workshop/jquery/autocomplete.htm
(I know, jQuery - yuck!)
The problem with this one (and others) is that the rendering breaks
when any of the strings contain html entity encoded characters. This
is because the dropdown list is html, but the text box value is raw
text. Fixing the code myself to reconcile the two looks like it will
become very messy.
If anyone could recommend a way to do this properly. (Either a plugin
for an existing framework or a tried and tested pattern for
implementing autocomplete in pure JS would be greatly appreciated)
Thanks