"; + print _("Error: no HTML email template found"); + print ""; + } + hunk ./library/sip_settings.php 7113 - $body = $smarty->fetch($tpl); + $bodyt = $smarty->fetch($tpl); + + if ($tpl_html) { + $bodyhtml = $smarty->fetch($tpl_html); + } + + include 'Mail.php'; + include 'Mail/mime.php' ; + + $hdrs = array( + 'From' => $this->support_email, + 'Subject' => $subject + ); + + $crlf = "\n"; + $mime = new Mail_mime($crlf); + + $mime->setTXTBody($bodyt); + + if ($tpl_html) { + $mime->setHTMLBody($bodyhtml); + } + + $body = $mime->get(); + $hdrs = $mime->headers($hdrs); + + $mail =& Mail::factory('mail'); hunk ./library/sip_settings.php 7141 - if (mail($this->email, $subject, $body, "From: $this->support_email") && !$skip_html) { + $mail->send($this->billing_email, $hdrs, $body); + + if ($mail->send($this->email, $hdrs, $body) && !$skip_html) { hunk ./library/sip_settings.php 7679 + function getEmailTemplateHTML($language='en') { + $file = "sip_settings_email_$language.html.tpl"; + $file2 = "sip_settings_email.html.tpl"; + + //print("templates_path = $this->templates_path"); + + if (file_exists("$this->templates_path/$this->reseller/$file")) { + return "$this->templates_path/$this->reseller/$file"; + } elseif (file_exists("$this->templates_path/$this->reseller/$file2")) { + return "$this->templates_path/$this->reseller/$file2"; + } elseif (file_exists("$this->templates_path/default/$file")) { + return "$this->templates_path/default/$file"; + } elseif (file_exists("$this->templates_path/default/$file2")) { + return "$this->templates_path/default/$file2"; + } else { + return false; + } + } + addfile ./templates/default/sip_settings_email.html.tpl hunk ./templates/default/sip_settings_email.html.tpl 1 + + +
+ + hunk ./templates/default/sip_settings_email.html.tpl 7 +{literal} + +{/literal} +
+
+ |
+