var chqbx_name = table2edit+'.createNewTab';
var chqbx = INPUT({'class':'createNewTableCheck editField',
'type':'checkbox', 'name':chqbx_name}, null);
var chqd = false;
[snip logic to determine wether to set checked]
if(chqd == 'on'){
setNodeAttribute(chqbx, 'checked');
}
When placed in the DOM the check box is not checked. To wait until
after I have called relaceChildNodes will require contortions
(widening
the scope of some variables) that I would rather avoid. I have the
element (chqbx) and I want to set an attribute in it, directly. How?
If I recall correctly, at least in IE, checkbox state is not retained
when the element is not in the page. You have to insert it in the
page, then set the attribute.
--Dethe
"Any idea that couldn't stand a few decades of neglect is not worth
anything." --Gabriel Garcia Marquez