]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Make the "mail a new password" text be a param.
authorterry%mozilla.org <>
Tue, 8 Feb 2000 06:11:53 +0000 (06:11 +0000)
committerterry%mozilla.org <>
Tue, 8 Feb 2000 06:11:53 +0000 (06:11 +0000)
CGI.pl
defparams.pl

diff --git a/CGI.pl b/CGI.pl
index a5c8c73213e79f403ad1cd83199b025e1e4c7f63..39cdbca1298e9b12ac9037882e4bd1dd05c63d4f 100644 (file)
--- a/CGI.pl
+++ b/CGI.pl
@@ -578,23 +578,11 @@ sub CheckEmailSyntax {
 sub MailPassword {
     my ($login, $password) = (@_);
     my $urlbase = Param("urlbase");
-    my $template = "From: bugzilla-daemon
-To: %s
-Subject: Your bugzilla password.
-
-To use the wonders of bugzilla, you can use the following:
-
- E-mail address: %s
-       Password: %s
-
- To change your password, go to:
- ${urlbase}userprefs.cgi
-
- (Your bugzilla and CVS password, if any, are not currently synchronized.
- Top hackers are working around the clock to fix this, as you read this.)
-";
-    my $msg = sprintf($template, $login . Param('emailsuffix'),
-                      $login, $password);
+    my $template = Param("passwordmail");
+    my $msg = PerformSubsts($template,
+                            {"mailaddress" => $login . Param('emailsuffix'),
+                             "login" => $login,
+                             "password" => $password});
 
     open SENDMAIL, "|/usr/lib/sendmail -t";
     print SENDMAIL $msg;
index 6bd398c73563afaa2c9cde0830b3f0b110587c69..742ca3746b0c3854c806f3d471010e0689c1c97f 100644 (file)
@@ -226,6 +226,28 @@ DefParam("warnfooterhtml",
          "</font>");
 
 
+DefParam("passwordmail",
+q{The email that gets sent to people to tell them their password.  Within
+this text, %mailaddress% gets replaced by the person's email address,
+%login% gets replaced by the person's login (usually the same thing), and
+%password% gets replaced by their password.  %<i>anythingelse</i>% gets
+replaced by the definition of that parameter (as defined on this page).},
+         "l",
+         q{From: bugzilla-daemon
+To: %mailaddress%
+Subject: Your Bugzilla password.
+
+To use the wonders of Bugzilla, you can use the following:
+
+ E-mail address: %login%
+       Password: %password%
+
+ To change your password, go to:
+ %urlbase%userprefs.cgi
+});
+
+
+
 DefParam("changedmail",
 q{The email that gets sent to people when a bug changes.  Within this
 text, %to% gets replaced by the assigned-to and reported-by people,