The problem seems to be at the .getAttribute('id'). IE simply wont grab the id of the element that it is on. Ive tried .getAttributeNode('id').value, attributes['id']. Nothing seems to work. I've been reading up on .getAttribute() method for IE and it looks sorta weird, but i cant find anything that has a solution for my problem.
mainContainer=document.getElementById(...
allInputs=mainContainer.getElementsByT...
for(e=0; e%26lt;allInputs.length; e++) {
// this is where it fails in IE. it wont grab the id of the current input
if(allInputs[e].getAttribute('id') == (g_id+'_'+(sib_id-1))) {
mainGroupInput=allInputs[e];
alert(allInputs[e].getAttribute('id'))... // works in FF
alert(allInputs[e].attributes['id'].va... // works in FF
if(mainGroupInput.checked==true) {
alert('checked');
} else {
alert('unchecked');
}
}
}
GetAttribute(), getAttribute('id') not working in internet explorer (ie)?microsoft sql server
Is there any reason you can't use (eg) allInputs[e].id ?
No comments:
Post a Comment