mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-06 19:53:56 +00:00
When using multiple email addresses with faxing commas are used between email addresses. The commas must be escaped this change automatically does the escaping so the end user doesn't have to do it.
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
|
||||
The Initial Developer of the Original Code is
|
||||
Mark J Crane <markjcrane@fusionpbx.com>
|
||||
Portions created by the Initial Developer are Copyright (C) 2008-2012
|
||||
Portions created by the Initial Developer are Copyright (C) 2008-2014
|
||||
the Initial Developer. All Rights Reserved.
|
||||
|
||||
Contributor(s):
|
||||
@@ -141,21 +141,25 @@ require_once "resources/paging.php";
|
||||
|
||||
if ($result_count > 0) {
|
||||
foreach($result as $row) {
|
||||
echo "<tr >\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_name']."</td>\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_extension']."</td>\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_email']." </td>\n";
|
||||
echo " <td valign='top' class='row_stylebg' width='35%'>".$row['fax_description']." </td>\n";
|
||||
echo " <td valign='top' align='right'>\n";
|
||||
if (permission_exists('fax_extension_edit')) {
|
||||
echo " <a href='fax_view.php?id=".$row['fax_uuid']."' alt='edit'>$v_link_label_edit</a>\n";
|
||||
}
|
||||
if (permission_exists('fax_extension_delete')) {
|
||||
echo " <a href='fax_delete.php?id=".$row['fax_uuid']."' alt='delete' onclick=\"return confirm('".$text['confirm-delete']."')\">$v_link_label_delete</a>\n";
|
||||
}
|
||||
echo " </td>\n";
|
||||
echo "</tr>\n";
|
||||
if ($c==0) { $c=1; } else { $c=0; }
|
||||
//remove the backslash
|
||||
$row['fax_email'] = str_replace("\\", "", $row['fax_email']);
|
||||
//show the fax extensions
|
||||
echo "<tr >\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_name']."</td>\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_extension']."</td>\n";
|
||||
echo " <td valign='top' class='".$row_style[$c]."'>".$row['fax_email']." </td>\n";
|
||||
echo " <td valign='top' class='row_stylebg' width='35%'>".$row['fax_description']." </td>\n";
|
||||
echo " <td valign='top' align='right'>\n";
|
||||
if (permission_exists('fax_extension_edit')) {
|
||||
echo " <a href='fax_view.php?id=".$row['fax_uuid']."' alt='edit'>$v_link_label_edit</a>\n";
|
||||
}
|
||||
if (permission_exists('fax_extension_delete')) {
|
||||
echo " <a href='fax_delete.php?id=".$row['fax_uuid']."' alt='delete' onclick=\"return confirm('".$text['confirm-delete']."')\">$v_link_label_delete</a>\n";
|
||||
}
|
||||
echo " </td>\n";
|
||||
echo "</tr>\n";
|
||||
//alternate the CSS class
|
||||
if ($c==0) { $c=1; } else { $c=0; }
|
||||
} //end foreach
|
||||
unset($sql, $result, $row_count);
|
||||
} //end if results
|
||||
|
||||
@@ -202,6 +202,9 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
//escape the commas with a backslash
|
||||
$fax_email = str_replace(",", "\\,", $fax_email);
|
||||
|
||||
//set the $php_bin
|
||||
//if (file_exists(PHP_BINDIR."/php")) { $php_bin = 'php'; }
|
||||
if (substr(strtoupper(PHP_OS), 0, 3) == "WIN") {
|
||||
@@ -513,6 +516,9 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
unset ($prep_statement);
|
||||
}
|
||||
|
||||
//remove the backslash
|
||||
$fax_email = str_replace("\\", "", $fax_email);
|
||||
|
||||
//set the dialplan_uuid
|
||||
if (strlen($dialplan_uuid) == 0) {
|
||||
$dialplan_uuid = uuid();
|
||||
|
||||
Reference in New Issue
Block a user