Fix the call center buttons which were broken for Queue names with a space in them

This commit is contained in:
Mark Crane 2014-07-08 02:22:32 +00:00
parent f08445592b
commit dba82d6d5a
1 changed files with 30 additions and 29 deletions

View File

@ -352,6 +352,7 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) {
$result = $prep_statement->fetchAll(PDO::FETCH_NAMED);
foreach ($result as &$row) {
$queue_name = $row["queue_name"];
$database_queue_name = $row["queue_name"];
$queue_extension = $row["queue_extension"];
$queue_strategy = $row["queue_strategy"];
$queue_moh_sound = $row["queue_moh_sound"];
@ -419,10 +420,10 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) {
echo "<td width='70%' align='right'>\n";
echo " <input type='button' class='btn' name='' alt='".$text['button-back']."' onclick=\"window.location='call_center_queues.php'\" value='".$text['button-back']."'>\n";
if ($action == "update") {
echo " <input type='button' class='btn' value='".$text['button-view']."' onclick=\"document.location.href='".PROJECT_PATH."/app/call_center_active/call_center_active.php?queue_name=$queue_name';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-load']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+load+$queue_name@".$_SESSION['domain_name']."';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-unload']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+unload+$queue_name@".$_SESSION['domain_name']."';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-reload']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+reload+$queue_name@".$_SESSION['domain_name']."';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-view']."' onclick=\"document.location.href='".PROJECT_PATH."/app/call_center_active/call_center_active.php?queue_name=$database_queue_name';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-load']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+load+$database_queue_name@".$_SESSION['domain_name']."';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-unload']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+unload+$database_queue_name@".$_SESSION['domain_name']."';\" />\n";
echo " <input type='button' class='btn' value='".$text['button-reload']."' onclick=\"document.location.href='cmd.php?cmd=api+callcenter_config+queue+reload+$database_queue_name@".$_SESSION['domain_name']."';\" />\n";
}
echo " <input type='submit' class='btn' value='".$text['button-save']."'>\n";
echo "</td>\n";