Select widget
Submitted by bill on Wed, 06/07/2006 - 06:29.
The ComboBox widget has been split into two separate widgets, ComboBox and Select (Select is a subclass of the ComboBox). The ComboBox widget was previously serving two functions:
1. an enhanced text <input> field where the user could input any value, or pick from a list of drop down "suggestions"
2. an enhanced version of <select>, where you had separate labels and values (ex: CA vs California), and the user could only pick one of the predefined values
#2 has been split into a separate widget called Select. The two major differences are that 1) the value submitted from the Select widget is the hidden value (CA), not the displayed value (California), and 2) the Select widget restricts the user to the set of predefined choices.
Compare the combo box test and select widget test
Thanks to Matthew Flanagan for the patch!
There's recently been a bunch of interest in the ComboBox widget, and I think there will be some more patches to come (there are still some outstanding bugs), but there's been a bunch of stuff fixed already, so take a look.
Bill
- bill's blog
- Login or register to post comments
- Subscribe blog
- Subscribe post

OK, I'm not sure if I'm
That might be a good point.
I agree with Adrian. Also, I
Adrian, A better way of
Tom, I'll do that, thanks
Patrick, A combobox as it's
I have a quick question.
Tom, I fully understand the
Is it possible to
Dynamically change the dataUrl
Hi there,
I've got 2 combo boxes:
Combo box 1: countries
Combo box 2: cities
I want the values in combo box 2 (cities) to change depending on the country selected in combo box 1.
Could you please help me with changing the dataUrl dynamically.
Thanks.
function countryOnChange(ctry) {
var cityField = dojo.widget.byId('cities');
cityField.textInputNode.value = ctry;
}
< input dojotype="ComboBox" value="this should never be seen - it is replaced!" dataurl="getCountries.php?type=json&matching=%{searchString}" onvaluechanged="countryOnChange(arguments[0]);" style="width: 300px;" name="country" id="country" mode="remote" >
< input dojotype="ComboBox" value="this should never be seen - it is replaced!" dataurl="getCities.php?type=json&matching=%{searchString}" onvaluechanged="citiesOnChange(arguments[0]);" style="width: 300px;" name="cities" id="cities" mode="remote" >
How would one go about using
I want to fill ComboBox with
Rajkumar Vakkada "Is it
Rajkumar, If you absolutely
Arrgh angle
Open the select/combobox
I'm searching a way to
Can someone give me a
As many of you probably know
As many of you probably know there is also a patch made to dojo 0.3.0 that modifies the behavior of select widget radically. This page has list of arguments why this implementation is "the real" select box. It has some very useful features such as support for paging and moving to the search result, not filtering alternatives.
dojo combo box
how can i make a dojo combo box non-editable....
how to write code for that...