summaryrefslogtreecommitdiffstats
path: root/web/lib
diff options
context:
space:
mode:
authorLukas Fleischer <archlinux@cryptocrack.de>2014-05-22 15:32:52 +0200
committerLukas Fleischer <archlinux@cryptocrack.de>2014-05-22 15:43:41 +0200
commit02e7df7631e0ec08cc3890a0d4202ed6f5331585 (patch)
tree12370d6bf34253d411377ab8bb0c8213b613a39e /web/lib
parentd062634ce2e8aff74d65faf5d3394e429bb2de63 (diff)
downloadaur-02e7df7631e0ec08cc3890a0d4202ed6f5331585.tar.gz
aur-02e7df7631e0ec08cc3890a0d4202ed6f5331585.tar.xz
Be friendly to newly registered users
Use "Welcome to the Arch User Repository" instead of "AUR Password Reset" as subject for the initial password reset email. Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/lib')
-rw-r--r--web/lib/acctfuncs.inc.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/web/lib/acctfuncs.inc.php b/web/lib/acctfuncs.inc.php
index 312f11bc..6ac34a0d 100644
--- a/web/lib/acctfuncs.inc.php
+++ b/web/lib/acctfuncs.inc.php
@@ -221,6 +221,7 @@ function process_account_form($UTYPE,$TYPE,$A,$U="",$T="",$S="",$E="",
"<strong>", htmlspecialchars($U,ENT_QUOTES), "</strong>");
print "<p>\n";
if ($send_resetkey) {
+ $subject = 'Welcome to the Arch User Repository';
$body = __('Welcome to %s! In order ' .
'to set an initial password ' .
'for your new account, ' .
@@ -230,7 +231,7 @@ function process_account_form($UTYPE,$TYPE,$A,$U="",$T="",$S="",$E="",
'pasting it into your ' .
'browser.',
$AUR_LOCATION);
- send_resetkey($email, $body);
+ send_resetkey($email, $subject, $body);
print __("A password reset key has been sent to your e-mail address.");
} else {
print __("Click on the Login link above to use your account.");
@@ -632,11 +633,12 @@ function create_resetkey($resetkey, $uid) {
* Send a reset key to a specific e-mail address
*
* @param string $email E-mail address of the user resetting their password
+ * @param string $subject Subject of the email
* @param string $body Body of the email
*
* @return void
*/
-function send_resetkey($email, $body) {
+function send_resetkey($email, $subject, $body) {
global $AUR_LOCATION;
$uid = uid_from_email($email);
@@ -658,7 +660,7 @@ function send_resetkey($email, $body) {
"From: aur-notify@archlinux.org\r\n" .
"X-Mailer: PHP\r\n" .
"X-MimeOLE: Produced By AUR";
- @mail($email, 'AUR Password Reset', $body, $headers);
+ @mail($email, $subject, $body, $headers);
}
}