[Dojo-interest] ComboBox submit

Simon Niederberger simon.niederberger at want.ch
Sat Dec 9 03:31:06 MST 2006


Hi Ray

I believe this is the default behavior for a ComboBox, which doesn't support
keys. You might be looking for the Select widget (dojoType="Select").

Simon

-----Original Message-----
From: Rares Vernica [mailto:rvernica at gmail.com] 
Sent: Samstag, 9. Dezember 2006 03:22
To: dojo-interest at dojotoolkit.org
Subject: [Dojo-interest] ComboBox submit

Hi,

I am using the ComboBox widget in a form. The ComboBox acts like it is
supposed to. The only problem is when the user is submitting the form.

When the form is submitted no key=value pair is created for the ComboBox
widget. All the other form elements work well.

Here is the code for my ComboBox widget:

<script type="text/javascript">
	dojo.require("dojo.widget.ComboBox");
	function setVal2(val){
		dojo.byId('value2').value=val;
	}
</script>

<select
     name="query"
     dojoType="ComboBox"
     autoComplete="false"
     dataUrl="/fr/persons/match/?query=%{searchString}"
     maxListLength="10"
     style="width: 450px;"
     mode="remote"
     onValueChanged="setVal2">
</select>

<div>Value: <input id="value2" name="query_value" type="text"></div>

The query_value variable gets set well, but the query variable is not
created.

Here is a sample from what "dataUrl" returns:

[["Michael Moses Neworleans LA", 3548], ...]

Thanks a lot,
Ray

_______________________________________________
Dojo FAQ: http://dojo.jot.com/FAQ
Dojo Book: http://manual.dojotoolkit.org/DojoDotBook
Dojo-interest at dojotoolkit.org
http://dojotoolkit.org/mailman/listinfo/dojo-interest






More information about the Dojo-interest mailing list