summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArun Persaud <arun@nubati.net>2013-01-19 11:53:39 -0800
committerArun Persaud <arun@nubati.net>2013-01-19 11:53:39 -0800
commit6c80e21d296f7c796edbbaca87caffe8d5c7dc48 (patch)
treec0b2642c1ad0489a4ea07644870dc5a82bb588d1
parentbe205de31c62e22c4347e2c3514efe945645d946 (diff)
downloade-DoKo-6c80e21d296f7c796edbbaca87caffe8d5c7dc48.tar.gz
e-DoKo-6c80e21d296f7c796edbbaca87caffe8d5c7dc48.tar.bz2
e-DoKo-6c80e21d296f7c796edbbaca87caffe8d5c7dc48.zip
BUGFIX: send emails in utf-8
-rw-r--r--include/functions.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/include/functions.php b/include/functions.php
index a332347..d9421f1 100644
--- a/include/functions.php
+++ b/include/functions.php
@@ -218,6 +218,10 @@ function sendmail($To,$Subject,$message)
if(isset($EMAIL_REPLY))
$header .= "From: e-DoKo daemon <$EMAIL_REPLY>\r\n";
+ $headers .= "Content-Type: text/plain; charset = \"UTF-8\";\r\n";
+ $headers .= "Content-Transfer-Encoding: 8bit\r\n";
+ $headers .= "\r\n";
+
if($debug)
{
/* display email on screen,
@@ -228,15 +232,12 @@ function sendmail($To,$Subject,$message)
"<a href=\"$1\">$1</a>", $message);
echo "<br />To: $To<br />";
- if($header != "")
- echo $header."<br />";
+ echo $header."<br />";
echo "Subject: $Subject <br />$message<br />\n";
}
else
- if($header != "")
- mail($To,$Subject,$message,$header);
- else
- mail($To,$Subject,$message);
+ mail($To,$Subject,$message,$header);
+
return;
}