Categories | Question details Back To List | ||
Dhtmlx Combo Hello again, I`m working on PRO version of Dhtmlx. I have a dhtmlXCombo with "n" options and I want each option to store apart from the value="" and text, extra attributes, for example: <complete> <option code="ABCD" value="2">TEST 1</option> <option code="AB 3" value="3">TEST 2</option> <option code="A 1" value="1">TEST 3</option> </complete> Is there a way to do this and the retrieve this values? Thanks a lot Andres Answer posted by Alex (support) on Nov 23, 2009 01:45 Hello, there is no public method to add additional attributes to the option. But custom solution is possible. For example, if you want to add "code" attribute, the dhtmlxcombo.js should be modified as follows: try to locate dhtmlXCombo_defaultOption.prototype.setValue = function(attr){ line and add here the highlighted line: dhtmlXCombo_defaultOption.prototype.setValue = function(attr){ Answer posted by Andres on Nov 23, 2009 04:58 Thanks a lot Alex! It worked perfect. |