aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorterry%mozilla.org <>2000-01-23 00:51:49 +0000
committerterry%mozilla.org <>2000-01-23 00:51:49 +0000
commit91f9bc0ff29f70e6eb610415c3c05848c765b683 (patch)
tree0f253eedaca7bfe7de79b4c5134608aa139695e3 /editkeywords.cgi
parentPatch by Holger Schurig <holger@holger.om.org> -- add new localconfig (diff)
downloadbugzilla-91f9bc0ff29f70e6eb610415c3c05848c765b683.tar.gz
bugzilla-91f9bc0ff29f70e6eb610415c3c05848c765b683.tar.bz2
bugzilla-91f9bc0ff29f70e6eb610415c3c05848c765b683.zip
Patch by Klaas Freitag <freitag@suse.de>, with modifications by me --
don't generate HTML tables with more than 50 lines, as browsers generally can't cope with huge tables.
Diffstat (limited to 'editkeywords.cgi')
-rwxr-xr-xeditkeywords.cgi12
1 files changed, 11 insertions, 1 deletions
diff --git a/editkeywords.cgi b/editkeywords.cgi
index 3443a5c3f..da9ec1b1c 100755
--- a/editkeywords.cgi
+++ b/editkeywords.cgi
@@ -125,7 +125,7 @@ my $action = trim($::FORM{action} || '');
if ($action eq "") {
PutHeader("Select keyword");
- print qq{
+ my $tableheader = qq{
<TABLE BORDER=1 CELLPADDING=4 CELLSPACING=0>
<TR BGCOLOR="#6666FF">
<TH ALIGN="left">Edit keyword ...</TH>
@@ -134,6 +134,10 @@ if ($action eq "") {
<TH ALIGN="left">Action</TH>
</TR>
};
+ print $tableheader;
+ my $line_count = 0;
+ my $max_table_size = 50;
+
SendSQL("SELECT keyworddefs.id, keyworddefs.name, keyworddefs.description,
COUNT(keywords.bug_id), keywords.bug_id
FROM keyworddefs LEFT JOIN keywords ON keyworddefs.id = keywords.keywordid
@@ -151,6 +155,12 @@ if ($action eq "") {
# what it had responded.
$bugs = 'none';
}
+ if ($line_count == $max_table_size) {
+ print "</table>\n$tableheader";
+ $line_count = 0;
+ }
+ $line_count++;
+
print qq{
<TR>
<TH VALIGN="top"><A HREF="editkeywords.cgi?action=edit&id=$id">$name</TH>