Hi all!
I need by
JS add several objects <input > of type checkbox. And names and quality of these objects may be
different in different cases After that I need to verify which of created objects are checked.
The problem is that submiting the form I do not have any of new created checkboxs. Moreover, if after cteation
of these checkbox I need to get desriptors of these checkbox-(I need it)
I run a circle like:
for (i=0; i< theForm.elements.length; i++) {
alert( theForm.elements[i].name );
but I do not see names or id's of these checkboxes!
I do it so:
var NewRow=document.getElementById("radio_table").inse rtRow(-1); // radio_table - table with checkboxes
var CheckBoxCell= NewRow.insertCell(-1); // Add new row
var ObjName= "templateRadio_tmplRootService"; // the njame of a new checkbox
var isChecked = ' "checked" '; // checkbox id checked
CheckBoxCell.innerHTML= "<INPUT TYPE=checkbox id=\""+ObjName+"\" name=\""+ObjName+"\" VALUE=\"Y\" "+isChecked+" > ";//+cn+" ("+objclass+","+objcategory+")";
CheckBoxCell.form= document.TemplateDbEditor; // I tried to set the property form of created cell?
alert("CheckBoxCell.innerHTML:::"+CheckBoxCell.inn erHTML); // look my html-code:
<input id="templateRadio_tmplRootService" name="templateRadio_tmplRootService" value="Y" checked= "checked" type="checkbox">
How may I do this?
Thanks in advance,
Nilov Serge.
Thanks in advance,
Nilov Serge.