From: Joe Hunt Date: Tue, 2 Mar 2010 12:00:30 +0000 (+0000) Subject: Bug sending email from/to a name with commas. Has been replaced with '' X-Git-Tag: 2.3-final~942 X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=7321f7485bdd4ea60778a8cb288408f1bb754e95;p=fa-stable.git Bug sending email from/to a name with commas. Has been replaced with '' --- diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 418aca8b..30549ad9 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,10 @@ Legend: ! -> Note $ -> Affected files +02-Mar-2010 Joe Hunt +# Bug sending email to a name with commas. Has been replaced with ''. +$ /reporting/includes/pdf_report.inc + 01-Mar-2010 Janusz Dobrowolski # [0000212] Selecting branch from popup was not working. $ /sales/manage/customer_branches.php diff --git a/reporting/includes/pdf_report.inc b/reporting/includes/pdf_report.inc index 9c86c2ec..2dcafc5c 100644 --- a/reporting/includes/pdf_report.inc +++ b/reporting/includes/pdf_report.inc @@ -926,10 +926,10 @@ class FrontReport extends Cpdf include("includes/doctext.inc"); } require_once($path_to_root . "/reporting/includes/class.mail.inc"); - $mail = new email($this->company['coy_name'], $this->company['email']); + $mail = new email(str_replace(",", "", $this->company['coy_name']), $this->company['email']); if (!isset($myrow['email']) || $myrow['email'] == '') $myrow['email'] = isset($myrow['contact_email']) ? $myrow['contact_email'] : ''; - $to = $myrow['DebtorName'] . " <" . $myrow['email'] . ">"; + $to = str_replace(",", "", $myrow['DebtorName']) . " <" . $myrow['email'] . ">"; $msg = $doc_Dear_Sirs . " " . $myrow['DebtorName'] . ",\n\n" . $doc_AttachedFile . " " . $subject . "\n\n"; if (isset($myrow['dimension_id']) && $myrow['dimension_id'] > 0 && $doctype == ST_SALESINVOICE) // helper for payment links