[Web] Various PHP 8 fixes, partly fixes #4219

This commit is contained in:
andryyy
2021-08-09 08:28:22 +02:00
parent 7e958c9b26
commit 2cd0b56b14
15 changed files with 524 additions and 506 deletions

View File

@@ -1,8 +1,8 @@
<?php
function fwdhost($_action, $_data = null) {
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/spf.inc.php';
global $redis;
global $lang;
global $redis;
global $lang;
$_data_log = $_data;
switch ($_action) {
case 'add':
@@ -57,7 +57,7 @@ function fwdhost($_action, $_data = null) {
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_data_log),
'msg' => array('forwarding_host_added', htmlspecialchars(implode(', ', $hosts)))
'msg' => array('forwarding_host_added', htmlspecialchars(implode(', ', (array)$hosts)))
);
break;
case 'edit':
@@ -180,4 +180,4 @@ function fwdhost($_action, $_data = null) {
return $fwdhostdetails;
break;
}
}
}