How do I find if an element is a certain element (like
HTMLTableRowEle ment) ?
Using "alert(type of el)" simply displays "object" while "alert(el)"
displays "HTMLTableRowEl ement".
el = document.getEle mentById('strin gValue');
I need to match this specific element because of problems with
"display: none/block" in non-IE browsers.
This doesnt work:
if (el == HTMLTableRowEle ment || el == 'HTMLTableRowEl ement') {
el.style.displa y = '';
} else {
el.style.displa y = 'block';
}
HTMLTableRowEle ment) ?
Using "alert(type of el)" simply displays "object" while "alert(el)"
displays "HTMLTableRowEl ement".
el = document.getEle mentById('strin gValue');
I need to match this specific element because of problems with
"display: none/block" in non-IE browsers.
This doesnt work:
if (el == HTMLTableRowEle ment || el == 'HTMLTableRowEl ement') {
el.style.displa y = '';
} else {
el.style.displa y = 'block';
}
Comment