X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2FEmailer.php;h=5962e9ec8f00ece8b0dc01141d2e0592166744a2;hb=86d3adaa5084639a1221fc74ac44d5508add25f4;hp=7aae57346e0bb08626eab9abab7257f9fab102d7;hpb=ee50b04382ec2168a1c96d6b8d129b82dd1af8da;p=friendica.git diff --git a/include/Emailer.php b/include/Emailer.php index 7aae57346e..5962e9ec8f 100644 --- a/include/Emailer.php +++ b/include/Emailer.php @@ -16,7 +16,7 @@ class Emailer { * @param additionalMailHeader additions to the smtp mail header * @param optional uid user id of the destination user */ - static public function send($params) { + public static function send($params) { call_hooks('emailer_send_prepare', $params); @@ -30,8 +30,8 @@ class Emailer { // generate a mime boundary $mimeBoundary =rand(0,9)."-" - .rand(10000000000,99999999999)."-" - .rand(10000000000,99999999999)."=:" + .rand(100000000,999999999)."-" + .rand(100000000,999999999)."=:" .rand(10000,99999); // generate a multipart/alternative message header @@ -51,7 +51,7 @@ class Emailer { "Content-Transfer-Encoding: base64\n\n" . $textBody . "\n"; - if (!$email_textonly && !is_null($htmlBody)){ + if (!$email_textonly && !is_null($params['htmlVersion'])){ $multipartMessageBody .= "--" . $mimeBoundary . "\n" . // text/html section "Content-Type: text/html; charset=UTF-8\n" . @@ -81,4 +81,3 @@ class Emailer { return $res; } } -?>