Topic: combobox filter (Page 1 of 1) |
|
---|---|
Paranoid (IV) Inmate From: cell 3736 |
posted 06-30-2009 09:31
I want to filter the items in a combo box based on partial, case-insensitive strings in a text box in real time using javascript. I don't know how to do it tho. |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 06-30-2009 10:12
simple, keep all you key=>value mappings in an object, code: comboBox.options = []; // or similar, don't know exactly. Clear the combobox anyhow. for (key in myEntries) { if (shouldBeShown(key)) comboBox.options[length(comboBox.options)] = ... }
|
Paranoid (IV) Inmate From: cell 3736 |
posted 06-30-2009 15:38
thanks |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 06-30-2009 15:52
I do not understand your question. |
Paranoid (IV) Inmate From: cell 3736 |
posted 06-30-2009 18:55
nope, i don't want the items that are actually selected, i want all the items that are in the left combobox that is named "selected items" |
Maniac (V) Mad Scientist with Finglongers From: Germany |
posted 07-01-2009 12:05
if you can't assign an onsumbit handler (which is what I'd do), |
Nervous Wreck (II) Inmate From: |
posted 05-31-2011 11:07
Edit TP: spam removed
|