I've been looking around for information on how well IE 5.5 handles
DOM script, but haven't found anything conclusive. I'm using script
to add rows to an existing table with code something like the
following:
function click() { alert(this.checked); }
var rowcount=1;
var tr, td, elem, colcount;
var table=document.getElementById( "theTable" );
var check_node=document.createElement( 'input' );
check_node.type='checkbox';
for( var idx=0; idx < 5; idx++ ) {
colcount=0;
tr=table.insertRow( rowcount++ );
td=tr.insertCell( colcount++ );
elem=td.appendChild( check_node.cloneNode(false) );
elem.checked=true;
elem.idx=idx;
elem.onclick=click;
td.appendChild( document.createTextNode('foo'+idx) );
}
Is this safe and advisable for IE 5.5/NS6 and higher?
--
Christopher Benson-Manica | I *should* know what I'm talking about - if I
ataru(at)cyberspace.org | don't, I need to know. Flames welcome.