Device - Edit: Updates for PHP 8.1
This commit is contained in:
parent
d7b3e25cd4
commit
3ea9e7d012
|
|
@ -769,7 +769,9 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
//get the device line settings
|
//get the device line settings
|
||||||
$row = $device_lines[0];
|
$row = $device_lines[0] ?? null;
|
||||||
|
|
||||||
|
if (!empty($row)) {
|
||||||
|
|
||||||
//set the outbound proxy settings
|
//set the outbound proxy settings
|
||||||
if (empty($row['outbound_proxy_primary'])) {
|
if (empty($row['outbound_proxy_primary'])) {
|
||||||
|
|
@ -800,6 +802,8 @@
|
||||||
$content .= "</AccountConfig>";
|
$content .= "</AccountConfig>";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
//build content for linphone
|
//build content for linphone
|
||||||
if ($device_template == "linphone/default") {
|
if ($device_template == "linphone/default") {
|
||||||
$content = "https://".$_SESSION['domain_name'].'/app/provision/index.php?address='.$device_address;
|
$content = "https://".$_SESSION['domain_name'].'/app/provision/index.php?address='.$device_address;
|
||||||
|
|
@ -808,7 +812,7 @@
|
||||||
|
|
||||||
//stream the file
|
//stream the file
|
||||||
if (!empty($content)) {
|
if (!empty($content)) {
|
||||||
$xml = html_entity_decode($xml, ENT_QUOTES, 'UTF-8');
|
$content = html_entity_decode($content, ENT_QUOTES, 'UTF-8');
|
||||||
|
|
||||||
require_once 'resources/qr_code/QRErrorCorrectLevel.php';
|
require_once 'resources/qr_code/QRErrorCorrectLevel.php';
|
||||||
require_once 'resources/qr_code/QRCode.php';
|
require_once 'resources/qr_code/QRCode.php';
|
||||||
|
|
@ -830,7 +834,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
//html image
|
//html image
|
||||||
if (!empty($content)) {
|
if (!empty($content) && !empty($image)) {
|
||||||
|
|
||||||
echo "<script>\n";
|
echo "<script>\n";
|
||||||
echo "\n";
|
echo "\n";
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue