diff options
author | jake%acutex.net <> | 2001-11-07 23:58:56 +0100 |
---|---|---|
committer | jake%acutex.net <> | 2001-11-07 23:58:56 +0100 |
commit | 4d26270e7c1984e8c1adf789f484d6e937019ef6 (patch) | |
tree | adb0e24b49a3e2dbdbe35c261f942985c63967a0 /template/default/attachment | |
parent | aacf0de9e6162afa6a716739ba2d57fc4e6e02bd (diff) | |
download | bugzilla-4d26270e7c1984e8c1adf789f484d6e937019ef6.tar.gz bugzilla-4d26270e7c1984e8c1adf789f484d6e937019ef6.tar.xz |
Bug 108547 - Make the JavaScript use proper DOM
Patch by Christopher Aillon <caillon@returnzero.com>
r= timeless@bemail.org, kiko@async.com.br
Diffstat (limited to 'template/default/attachment')
-rwxr-xr-x | template/default/attachment/edit.atml | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/template/default/attachment/edit.atml b/template/default/attachment/edit.atml index ac9f327d0..ee6d005e7 100755 --- a/template/default/attachment/edit.atml +++ b/template/default/attachment/edit.atml @@ -160,18 +160,18 @@ function hideElementById(id) { var elm = document.getElementById(id); - if (!elm) return; - - elm.style.setProperty('display', 'none', ''); + if (elm) { + elm.style.display = 'none'; + } } function showElementById(id, val) { var elm = document.getElementById(id); - if (!elm) return; - - if (!val) val = 'inline'; - elm.style.setProperty('display', val, ''); + if (elm) { + if (!val) val = 'inline'; + elm.style.display = val; + } } function normalizeComments() @@ -181,15 +181,14 @@ var small = document.getElementById('smallCommentFrame'); var big = document.getElementById('editFrame'); - if ( small.style.getProperty('display') == 'none' ) + if ( small.style.display == 'none' ) { small.parentNode.removeChild(small); } - if ( big.style.getProperty('display') == 'none' ) + if ( big.style.display == 'none' ) { big.parentNode.removeChild(big); } - } </script> |