diff --git a/htdocs/admin/mails.php b/htdocs/admin/mails.php index 5a8881b656d..d9a63424b83 100644 --- a/htdocs/admin/mails.php +++ b/htdocs/admin/mails.php @@ -146,8 +146,8 @@ if (($_POST['action'] == 'send' || $_POST['action'] == 'sendhtml') if ($_POST['action'] == 'sendhtml') $msgishtml=1; // Force message to HTML // Pratique les substitutions sur le sujet et message - $subject=make_substitutions($subject,$substitutionarrayfortest); - $body=make_substitutions($body,$substitutionarrayfortest); + $subject=make_substitutions($subject,$substitutionarrayfortest,$langs); + $body=make_substitutions($body,$substitutionarrayfortest,$langs); require_once(DOL_DOCUMENT_ROOT."/lib/CMailFile.class.php"); $mailfile = new CMailFile($subject,$sendto,$email_from,$body, diff --git a/htdocs/comm/mailing/fiche.php b/htdocs/comm/mailing/fiche.php index b281fd4a24d..c359986b6ca 100644 --- a/htdocs/comm/mailing/fiche.php +++ b/htdocs/comm/mailing/fiche.php @@ -184,8 +184,8 @@ if ($_POST["action"] == 'sendallconfirmed' && $_POST['confirm'] == 'yes') ); $substitutionisok=true; - $newsubject=make_substitutions($subject,$substitutionarray); - $newmessage=make_substitutions($message,$substitutionarray); + $newsubject=make_substitutions($subject,$substitutionarray,$langs); + $newmessage=make_substitutions($message,$substitutionarray,$langs); // Fabrication du mail $mail = new CMailFile($newsubject, $sendto, $from, $newmessage, @@ -300,8 +300,8 @@ if ($_POST["action"] == 'send' && empty($_POST["cancel"])) if (preg_match('/[\s\t]*/i',$message)) $msgishtml=1; // Pratique les substitutions sur le sujet et message - $mil->sujet=make_substitutions($mil->sujet,$substitutionarrayfortest); - $mil->body=make_substitutions($mil->body,$substitutionarrayfortest); + $mil->sujet=make_substitutions($mil->sujet,$substitutionarrayfortest,$langs); + $mil->body=make_substitutions($mil->body,$substitutionarrayfortest,$langs); $mailfile = new CMailFile($mil->sujet,$mil->sendto,$mil->email_from,$mil->body, $arr_file,$arr_mime,$arr_name,'', '', 0, $msgishtml,$mil->email_errorsto,$arr_css); diff --git a/htdocs/html.formmail.class.php b/htdocs/html.formmail.class.php index 47a1da9d095..50f924d9da3 100644 --- a/htdocs/html.formmail.class.php +++ b/htdocs/html.formmail.class.php @@ -384,7 +384,7 @@ class FormMail // Topic if ($this->withtopic) { - $this->withtopic=make_substitutions($this->withtopic,$this->substit); + $this->withtopic=make_substitutions($this->withtopic,$this->substit,$langs); print "