Hi,
I created a dijit.form.multiselect control and populated it with hardcoded data in the create.jspx - for testing.
That works fine. Now, I need to populate it with external XML data at onload time. How do I do that? Most materials I read on this subject either uses a json data file or an URI as data source. Furthermore, is there any applicable examples that I can follow?
In create.jspx, I have this:
Code:
<div id="roo_material_couIds">
<label for="_couIds_id">Materials:</label>
<spring:bind path="couIds">
<form:select id="couIds" path="couIds">
<form:option value="1">Material 1</form:option>
<form:option value="2">Material 2</form:option>
<form:option value="3">Material 3</form:option>
<form:option value="4">Material 4</form:option>
</form:select>
</spring:bind> <script type="text/javascript"> Spring.addDecoration(new Spring.ElementDecoration({elementId : "couIds",
widgetType : "dijit.form.MultiSelect", widgetAttrs : {required : true,overflow:scroll=yes
trim : true, promptMessage : "Select Coupons", invalidMessage : ""}})) </script>
Any info will be greatly appreciated.