Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Raj Konda on Oct 07, 2008 19:46
open dhtmlx forum
DHTMXCOMBO - How to create dynamic options

Hi all.
I am having 2combos one state,one Cities When I change the state I am making a call to server (AJAX) to get the cities but How to create the options in the Cities drop down. If you can share a sample code that could be very helpful

Regards
Raj
Answer posted by Support on Oct 08, 2008 03:43
There are two possible solutions

a) create two combos and attach event code as
    combo.attachEvent("onChange",function(){
           combo2.loadXML("some.php?country="+combo.getActualValue());
    });

b) You can use combo - grouping functionality
           http://dhtmlx.com/docs/products/dhtmlxCombo/samples/initialization/combo_groups.html?un=1223463963000