Accent in emails
This commit is contained in:
parent
e4ac17e34d
commit
6ebaf0fecf
@ -138,7 +138,14 @@ class Question
|
|||||||
return $this->answers;
|
return $this->answers;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function mail_utf8($to, $subject = '(No subject)',
|
||||||
|
$message = '', $header = '')
|
||||||
|
{
|
||||||
|
$header_ = 'MIME-Version: 1.0' . "\r\n" .
|
||||||
|
'Content-type: text/plain; charset=UTF-8' . "\r\n";
|
||||||
|
return (mail($to, '=?UTF-8?B?'.base64_encode($subject).'?=',
|
||||||
|
$message, $header_ . $header));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -84,6 +84,8 @@ class QuestionsFile
|
|||||||
$this->treeXML->formatOutput = true;
|
$this->treeXML->formatOutput = true;
|
||||||
$this->treeXML->save($this->filename);
|
$this->treeXML->save($this->filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
@ -103,7 +103,7 @@ cette adresse email.\n\n"
|
|||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
if (mail($to, $subject, $message, $headers))
|
if ($quest->mail_utf8($to, $subject, $message, $headers))
|
||||||
{
|
{
|
||||||
echo ("Email sent");
|
echo ("Email sent");
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user