diff --git a/app/bridges/bridges.php b/app/bridges/bridges.php
index b48c7ba937..cad7da81f9 100644
--- a/app/bridges/bridges.php
+++ b/app/bridges/bridges.php
@@ -86,7 +86,7 @@
}
}
-//get order and order by and sanatize the values
+//get order and order by
$order_by = $_GET["order_by"];
$order = $_GET["order"];
@@ -124,8 +124,7 @@
if ($_GET['show'] == "all" && permission_exists('bridge_all')) {
$param .= "&show=all";
}
- $page = $_GET['page'];
- if (strlen($page) == 0) { $page = 0; $_GET['page'] = 0; }
+ $page = is_numeric($_GET['page']) ? $_GET['page'] : 0;
list($paging_controls, $rows_per_page) = paging($num_rows, $param, $rows_per_page);
list($paging_controls_mini, $rows_per_page) = paging($num_rows, $param, $rows_per_page, true);
$offset = $rows_per_page * $page;
@@ -225,10 +224,10 @@
}
echo "
- Portions created by the Initial Developer are Copyright (C) 2008-2012
+ Portions created by the Initial Developer are Copyright (C) 2008-2019
the Initial Developer. All Rights Reserved.
Contributor(s):
@@ -101,7 +101,7 @@
//prepare to page the results
$sql = "select count(*) from view_call_block ";
$sql .= "where domain_uuid = :domain_uuid ";
- if (!permission_exists('call_block_all') && count($_SESSION['user']['extension']) > 0) {
+ if (!permission_exists('call_block_all') && is_array($_SESSION['user']['extension'] && count($_SESSION['user']['extension']) > 0)) {
$sql .= "and extension_uuid in (";
$x = 0;
foreach ($_SESSION['user']['extension'] as $field) {
@@ -131,7 +131,7 @@
//get the list
$sql = "select * from view_call_block ";
$sql .= "where domain_uuid = :domain_uuid ";
- if (!permission_exists('call_block_all') && count($_SESSION['user']['extension']) > 0) {
+ if (!permission_exists('call_block_all') && is_array($_SESSION['user']['extension'] && count($_SESSION['user']['extension']) > 0)) {
$sql .= "and extension_uuid in (";
$x = 0;
foreach ($_SESSION['user']['extension'] as $field) {
diff --git a/app/call_block/call_block_edit.php b/app/call_block/call_block_edit.php
index 30a60b3193..b87f646102 100644
--- a/app/call_block/call_block_edit.php
+++ b/app/call_block/call_block_edit.php
@@ -440,7 +440,7 @@
unset($sql, $parameters);
}
- if (!permission_exists('call_block_all')) {
+ if (!permission_exists('call_block_all') && is_array($_SESSION['user']['extension'])) {
foreach ($_SESSION['user']['extension'] as $assigned_extension) {
$assigned_extensions[$assigned_extension['extension_uuid']] = $assigned_extension['user'];
}
diff --git a/app/call_recordings/call_recordings.php b/app/call_recordings/call_recordings.php
index 9c2e60a37d..f62e35871e 100644
--- a/app/call_recordings/call_recordings.php
+++ b/app/call_recordings/call_recordings.php
@@ -248,7 +248,7 @@
//echo " ".escape($row['call_recording_base64'])." | \n";
echo " ";
if (permission_exists('xml_cdr_details')) {
- echo " $v_link_label_view";
+ echo " $v_link_label_view";
}
if (permission_exists('call_recording_edit')) {
echo " |