summaryrefslogtreecommitdiffstats
path: root/js
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2011-07-26 11:06:11 +0200
committerFrédéric Buclin <LpSolit@gmail.com>2011-07-26 11:06:11 +0200
commit7ae7ccb35d64116573ae2611a752b4fd6a147dce (patch)
tree1b449f409297bf19ad58eff2a54d49dbab2b3b2b /js
parent2767ac53baac9ddf0ae288f49b120f581abefb63 (diff)
downloadbugzilla-7ae7ccb35d64116573ae2611a752b4fd6a147dce.tar.gz
bugzilla-7ae7ccb35d64116573ae2611a752b4fd6a147dce.tar.xz
Bug 647158: The Error Console in Firefox reports
"unbalanced tree was written using document.write()" when reporting a new bug or when visiting the "User Authentication" panel in the Parameters page r=glob a=LpSolit
Diffstat (limited to 'js')
-rw-r--r--js/attachment.js15
1 files changed, 14 insertions, 1 deletions
diff --git a/js/attachment.js b/js/attachment.js
index dfa6d472d..7861164b1 100644
--- a/js/attachment.js
+++ b/js/attachment.js
@@ -309,7 +309,7 @@ function hideElementById(id)
}
}
-function showElementById(id, val)
+function showElementById(id)
{
var elm = document.getElementById(id);
if (elm) {
@@ -345,3 +345,16 @@ function toggle_attachment_details_visibility ( )
}
}
+/* Used in bug/create.html.tmpl to show/hide the attachment field. */
+
+function handleWantsAttachment(wants_attachment) {
+ if (wants_attachment) {
+ hideElementById('attachment_false');
+ showElementById('attachment_true');
+ }
+ else {
+ showElementById('attachment_false');
+ hideElementById('attachment_true');
+ clearAttachmentFields();
+ }
+}