set utf-8 on all emails
This commit is contained in:
parent
c3b42fdbcb
commit
de131c9e58
|
@ -1415,7 +1415,9 @@ function new_follower($importer,$contact,$datarray,$item) {
|
|||
$res = mail($r[0]['email'],
|
||||
t("You have a new follower at ") . $a->config['sitename'],
|
||||
$email,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] );
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -651,7 +651,11 @@ function dfrn_confirm_post(&$a,$handsfree = null) {
|
|||
);
|
||||
|
||||
$res = mail($r[0]['email'], sprintf( t("Connection accepted at %s") , $a->config['sitename']),
|
||||
$email_tpl, 'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
if(!$res) {
|
||||
// pointless throwing an error here and confusing the person at the other end of the wire.
|
||||
}
|
||||
|
|
|
@ -401,7 +401,11 @@ function dfrn_notify_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($importer['email'], sprintf(t('%s commented on an item at %s'), $from , $a->config['sitename']),
|
||||
$email_tpl, "From: " . t('Administrator') . '@' . $a->get_hostname() );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
}
|
||||
}
|
||||
xml_status(0);
|
||||
|
@ -487,7 +491,11 @@ function dfrn_notify_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($importer['email'], sprintf( t("%s commented on an item at %s") , $from ,$a->config['sitename']),
|
||||
$email_tpl, "From: ".t("Administrator") . "@". $a->get_hostname() );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -544,7 +544,10 @@ function dfrn_request_content(&$a) {
|
|||
$res = mail($r[0]['email'],
|
||||
t("Introduction received at ") . $a->config['sitename'],
|
||||
$email,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] );
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
// This is a redundant notification - no point throwing errors if it fails.
|
||||
}
|
||||
if($auto_confirm) {
|
||||
|
|
|
@ -30,7 +30,11 @@ function invite_post(&$a) {
|
|||
}
|
||||
|
||||
$res = mail($recip, sprintf(t('Please join my network on %s'), $a->config['sitename']),
|
||||
$message, "From: " . $a->user['email']);
|
||||
$message,
|
||||
"From: " . $a->user['email'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
if($res) {
|
||||
$total ++;
|
||||
}
|
||||
|
|
11
mod/item.php
11
mod/item.php
|
@ -472,7 +472,10 @@ function item_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($user['email'], sprintf( t("%s commented on your item at %s") ,$from,$a->config['sitename']),
|
||||
$email_tpl,"From: " . t("Administrator") . "@" . $a->get_hostname() );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -495,7 +498,11 @@ function item_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($user['email'], sprintf( t("%s posted on your profile wall at %s") ,$from, $a->config['sitename']),
|
||||
$email_tpl,"From: " . t("Administrator") . "@" . $a->get_hostname() );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -36,7 +36,11 @@ function lostpass_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($email, sprintf( t('Password reset requested at %s'),$a->config['sitename']),
|
||||
$email_tpl, 'From: ' . t('Administrator') . '@' . $_SERVER[SERVER_NAME]);
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
|
||||
goaway($a->get_baseurl());
|
||||
}
|
||||
|
@ -94,7 +98,10 @@ function lostpass_content(&$a) {
|
|||
'$new_password' => $new_password,
|
||||
'$uid' => $newuid ));
|
||||
|
||||
$res = mail($email,"Your password has changed at {$a->config['sitename']}",$email_tpl,"From: Administrator@{$_SERVER[SERVER_NAME]}");
|
||||
$res = mail($email,"Your password has changed at {$a->config['sitename']}",$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
return $o;
|
||||
}
|
||||
|
|
|
@ -329,7 +329,10 @@ function register_post(&$a) {
|
|||
'$uid' => $newuid ));
|
||||
|
||||
$res = mail($email, sprintf(t('Registration details for %s'), $a->config['sitename']),
|
||||
$email_tpl, 'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME']);
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
|
||||
if($res) {
|
||||
|
@ -366,8 +369,10 @@ function register_post(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($a->config['admin_email'], sprintf(t('Registration request at %s'), $a->config['sitename']),
|
||||
$email_tpl,'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME']);
|
||||
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
if($res) {
|
||||
notice( t('Your registration is pending approval by the site owner.') . EOL ) ;
|
||||
goaway($a->get_baseurl());
|
||||
|
|
|
@ -90,7 +90,10 @@ function regmod_content(&$a) {
|
|||
));
|
||||
|
||||
$res = mail($user[0]['email'], sprintf(t('Registration details for %s'), $a->config['sitename']),
|
||||
$email_tpl,'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] );
|
||||
$email_tpl,
|
||||
'From: ' . t('Administrator') . '@' . $_SERVER['SERVER_NAME'] . "\n"
|
||||
. 'Content-type: text/plain; charset=UTF-8' . "\n"
|
||||
. 'Content-transfer-encoding: 8bit' );
|
||||
|
||||
if($res) {
|
||||
notice( t('Account approved.') . EOL );
|
||||
|
|
Loading…
Reference in a new issue