diff options
-rwxr-xr-x | buglist.cgi | 14 | ||||
-rw-r--r-- | defparams.pl | 4 | ||||
-rwxr-xr-x | reports.cgi | 8 |
3 files changed, 19 insertions, 7 deletions
diff --git a/buglist.cgi b/buglist.cgi index 8d3182200..d780e2af2 100755 --- a/buglist.cgi +++ b/buglist.cgi @@ -568,16 +568,16 @@ my $buglist = join(":", @bugarray); # This is stupid. We really really need to move the quip list into the DB! my $quip; -if (open (COMMENTS, "<data/comments")) { +if (Param('usequip')){ + if (open (COMMENTS, "<data/comments")) { my @cdata; while (<COMMENTS>) { - push @cdata, $_; + push @cdata, $_; } close COMMENTS; $quip = $cdata[int(rand($#cdata + 1))]; -} -if (!defined $quip) { - $quip = "Bugzilla would like to put a random quip here, but nobody has entered any."; + } + $quip ||= "Bugzilla would like to put a random quip here, but nobody has entered any."; } @@ -612,7 +612,9 @@ if ($toolong) { print "Next/Prev/First/Last buttons won't appear.</h2>\n"; } -print "<HR><A HREF=newquip.html><I>$quip</I></A></CENTER>\n"; +if (Param('usequip')){ + print "<HR><A HREF=newquip.html><I>$quip</I></A></CENTER>\n"; +} print "<HR SIZE=10>$tablestart\n"; print $::bugl; print "</TABLE>\n"; diff --git a/defparams.pl b/defparams.pl index ee85802e8..a7c4ba060 100644 --- a/defparams.pl +++ b/defparams.pl @@ -110,6 +110,10 @@ sub check_urlbase { return ""; } +DefParam("usequip", + "If this is on, Bugzilla displays a silly quip at the beginning of buglists, and lets users add to the list of quips.", + "b", + 1); DefParam("usedespot", "If this is on, then we are using the Despot system to control our database of users. Bugzilla won't ever write into the user database, it will let the Despot code maintain that. And Bugzilla will send the user over to Despot URLs if they need to change their password. Also, in that case, Bugzilla will treat the passwords stored in the database as being crypt'd, not plaintext.", diff --git a/reports.cgi b/reports.cgi index 21cfd780e..0b78969af 100755 --- a/reports.cgi +++ b/reports.cgi @@ -147,7 +147,13 @@ $charts <td align=left> <input type=checkbox name=links checked value=1> Links to Bugs<br> <input type=checkbox name=banner checked value=1> Banner<br> -<input type=checkbox name=quip value=1> Quip<br> +FIN + if (Param('usequip')) { + print "<input type=checkbox name=quip value=1> Quip<br>"; + } else { + print "<input type=hidden name=quip value=0>"; + } + print <<FIN; </td> </tr> <tr> |