var dyn_carsOptionTree = [['205',[['Sandero','2363']]],['26',[['Focus','253']]],['34',[['i10','1301'],['i30','1286'],['i40','2191'],['ix20','2168'],['Tucson','983']]],['61',[['Micra','521'],['Qashqai','1145']]],['63',[['Corsa','871']]],['67',[['208','2230'],['308','1241']]],['72',[['Captur','2400'],['Fluence','2169'],['Kadjar','2538'],['Master','1104'],['Megane','619']]],['78',[['Leon','673']]],['80',[['Rapid','2364']]],['88',[['Corolla','730']]],['93',[['Golf','812'],['Passat','817']]]] function populateTarget(name,triggerObj,targetObj,emptyText) { eval ('tree = ' + name + 'OptionTree') triggerValue = getValue(triggerObj) for (i=0;i -1) value = formObj.options[formObj.selectedIndex].value } else { if (formObj.length) { // radio for (var b = 0; b < formObj.length; b++) if (formObj[b].checked) value = formObj[b].value } else if (formObj.checked) // checkbox value = formObj.value } return value }