Specifying multiple recipients in $conf['notify'] does not work as expected.
When putting a value like "
user1@domain1.org,
user2@domain2.org", the following To: header will be generated:
To: "<
user1@domain1.org> To": "" <
user2@domain2.org>
The usual MTA won't deliver this mail correctly.
A quick (and most likely not elegant) fix to the problem:
--- dokuwiki-2005-05-07/inc/mail.php 2005-05-07 11:22:54.000000000 +0200
+++ dokuwiki-2005-05-07-patched/inc/mail.php 2005-05-20 18:44:37.000000000 +0200
@@ -109,8 +109,13 @@
// no text was given
if(empty($text)){
- $headers .= $header.': <'.$addr.'>'.MAILHEADER_EOL;
- continue;
+ if($headers == ''){
+ $headers = $header.': <'.$addr.'>';
+ continue;
+ }else{
+ $headers .= ', <'.$addr.'>';
+ continue;
+ }
}
if(defined('MAILHEADER_ASCIIONLY')){
@@ -125,7 +130,11 @@
}
//construct header
- $headers .= $header.': '.$text.' <'.$addr.'>'.MAILHEADER_EOL;
+ if($headers == ''){
+ $headers = $header.': "'.$text.'" <'.$addr.'>';
+ }else{
+ $headers .= ', "'.$text.'" <'.$addr.'>';
+ }
}
return $headers;