summaryrefslogtreecommitdiffstats
path: root/describekeywords.cgi
diff options
context:
space:
mode:
authorterry%mozilla.org <>2000-01-23 01:51:49 +0100
committerterry%mozilla.org <>2000-01-23 01:51:49 +0100
commit91f9bc0ff29f70e6eb610415c3c05848c765b683 (patch)
tree0f253eedaca7bfe7de79b4c5134608aa139695e3 /describekeywords.cgi
parent3bf8bf093bef432fba9b18cf90cd0ddcdb7fbef7 (diff)
downloadbugzilla-91f9bc0ff29f70e6eb610415c3c05848c765b683.tar.gz
bugzilla-91f9bc0ff29f70e6eb610415c3c05848c765b683.tar.xz
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 'describekeywords.cgi')
-rwxr-xr-xdescribekeywords.cgi11
1 files changed, 10 insertions, 1 deletions
diff --git a/describekeywords.cgi b/describekeywords.cgi
index fc0fe10bf..c80158267 100755
--- a/describekeywords.cgi
+++ b/describekeywords.cgi
@@ -31,7 +31,7 @@ print "Content-type: text/html\n\n";
PutHeader("Bugzilla keyword description");
-print qq{
+my $tableheader = qq{
<TABLE BORDER=1 CELLPADDING=4 CELLSPACING=0>
<TR BGCOLOR="#6666FF">
<TH ALIGN="left">Name</TH>
@@ -40,6 +40,10 @@ print qq{
</TR>
};
+print $tableheader;
+my $line_count = 0;
+my $max_table_size = 50;
+
SendSQL("SELECT keyworddefs.name, keyworddefs.description,
COUNT(keywords.bug_id), keywords.bug_id
FROM keyworddefs LEFT JOIN keywords ON keyworddefs.id=keywords.keywordid
@@ -59,6 +63,11 @@ while (MoreSQLData()) {
} else {
$bugs = "none";
}
+ if ($line_count == $max_table_size) {
+ print "</table>\n$tableheader";
+ $line_count = 0;
+ }
+ $line_count++;
print qq{
<TR>
<TH>$name</TH>