summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2012-08-05 20:59:58 +0200
committerAndreas Gohr <andi@splitbrain.org>2012-08-05 20:59:58 +0200
commit465e809be9a7b9bbf06feb7f47814582eadb0cf4 (patch)
tree3c85a88110f296fb6404e176c8d9627420d2e9d1
parentf7cefc02a20fa93edb9fdf171c47c6abbcb20552 (diff)
downloadrpg-465e809be9a7b9bbf06feb7f47814582eadb0cf4.tar.gz
rpg-465e809be9a7b9bbf06feb7f47814582eadb0cf4.tar.bz2
renamed mailfromnon to mailfromnobody, use in subscriptions
-rw-r--r--inc/mail.php6
-rw-r--r--inc/subscription.php2
2 files changed, 5 insertions, 3 deletions
diff --git a/inc/mail.php b/inc/mail.php
index fd040a8ce..d0ea651bf 100644
--- a/inc/mail.php
+++ b/inc/mail.php
@@ -32,7 +32,7 @@ if (!defined('PREG_PATTERN_VALID_EMAIL')) define('PREG_PATTERN_VALID_EMAIL', '['
/**
* Prepare mailfrom replacement patterns
*
- * Also prepares a mailfromnone config that contains an autoconstructed address
+ * Also prepares a mailfromnobody config that contains an autoconstructed address
* if the mailfrom one is userdependent and this might not be wanted (subscriptions)
*
* @author Andreas Gohr <andi@splitbrain.org>
@@ -72,9 +72,9 @@ function mail_setup(){
// any replacements done? set different mailfromnone
if($from != $conf['mailfrom']){
- $conf['mailfromnone'] = $noreply;
+ $conf['mailfromnobody'] = $noreply;
}else{
- $conf['mailfromnone'] = $from;
+ $conf['mailfromnobody'] = $from;
}
$conf['mailfrom'] = $from;
}
diff --git a/inc/subscription.php b/inc/subscription.php
index d1ee0397a..b4e5d2edd 100644
--- a/inc/subscription.php
+++ b/inc/subscription.php
@@ -373,6 +373,7 @@ function subscription_send_list($subscriber_mail, $ids, $ns_id) {
* @param string $id The page or namespace id
* @param string $template The name of the mail template
*
+ * @return bool
* @author Adrian Lang <lang@cosmocode.de>
*/
function subscription_send($subscriber_mail, $replaces, $subject, $id, $template) {
@@ -387,6 +388,7 @@ function subscription_send($subscriber_mail, $replaces, $subject, $id, $template
$mail->bcc($subscriber_mail);
$mail->subject($subject);
$mail->setBody($text,$trep);
+ $mail->from($conf['mailfromnobody']);
$mail->setHeader(
'List-Unsubscribe',
'<'.wl($id,array('do'=>'subscribe'),true,'&').'>',