mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-25 10:09:21 +00:00
Frytimo pr patches for php8.1 (#6630)
* Passing null to parameter #2 ($string) of type string is deprecated * Passing null to parameter #1 ($string) of type string is deprecated * php 8.1 fixes * php 8.1 fixes - replace strlen($var) > 0 with !empty($var) * php 8.1 fixes - replace ${var} with {$var} * php 8.1 fixes - replace ${var} with {$var} * php 8.1 fixes - replace ${var} with {$var} * php 8.1 fixes - replace ${var} with {$var} * php 8.1 fixes - strlower with null * php 8.1 fixes - strreplace with null * php 8.1 fixes - passing null to base64_decode * php 8.1 fixes - check for false and check for null on $this->dir * php 8.1 fixes - remove assignment of $db variable to modules object * php 8.1 fixes - avoid sending null to substr * php 8.1 fixes - change ${var} to {$var} * php 8.1 fixes - check for null before preg_replace * php 8.1 fixes - remove setting db variable on domains object * php 8.1 fixes - set empty string if $row['domain_setting_subcategory'] is null * php 8.1 fixes - set empty string if $_REQUEST['show'] is not available * php 8.1 fixes * php 8.1 fixes - correct $_POST checking syntax * php 8.1 fixes - correct $_POST variables * php 8.1 fixes * Use brackets consistently * Update user_setting_edit.php * Change to not empty * Update device.php * Update text.php --------- Co-authored-by: Tim Fry <tim@voipstratus.com> Co-authored-by: FusionPBX <markjcrane@gmail.com>
This commit is contained in:
@@ -73,7 +73,7 @@
|
||||
}
|
||||
|
||||
//process the user data and save it to the database
|
||||
if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
if (count($_POST) > 0 && empty($_POST["persistformvar"])) {
|
||||
|
||||
//validate the token
|
||||
$token = new token;
|
||||
@@ -84,7 +84,7 @@
|
||||
}
|
||||
|
||||
//process the http post data by submitted action
|
||||
if ($_POST['action'] != '' && strlen($_POST['action']) > 0) {
|
||||
if ($_POST['action'] != '' && !empty($_POST['action'])) {
|
||||
|
||||
//prepare the array(s)
|
||||
//send the array to the database class
|
||||
@@ -118,21 +118,21 @@
|
||||
|
||||
//check for all required data
|
||||
$msg = '';
|
||||
//if (strlen($fax_uuid) == 0) { $msg .= $text['message-required']." ".$text['label-fax_uuid']."<br>\n"; }
|
||||
if (strlen($fax_date) == 0) { $msg .= $text['message-required']." ".$text['label-fax_date']."<br>\n"; }
|
||||
if (strlen($hostname) == 0) { $msg .= $text['message-required']." ".$text['label-hostname']."<br>\n"; }
|
||||
//if (strlen($fax_caller_id_name) == 0) { $msg .= $text['message-required']." ".$text['label-fax_caller_id_name']."<br>\n"; }
|
||||
//if (strlen($fax_caller_id_number) == 0) { $msg .= $text['message-required']." ".$text['label-fax_caller_id_number']."<br>\n"; }
|
||||
if (strlen($fax_number) == 0) { $msg .= $text['message-required']." ".$text['label-fax_number']."<br>\n"; }
|
||||
//if (strlen($fax_prefix) == 0) { $msg .= $text['message-required']." ".$text['label-fax_prefix']."<br>\n"; }
|
||||
//if (strlen($fax_email_address) == 0) { $msg .= $text['message-required']." ".$text['label-fax_email_address']."<br>\n"; }
|
||||
if (strlen($fax_file) == 0) { $msg .= $text['message-required']." ".$text['label-fax_file']."<br>\n"; }
|
||||
if (strlen($fax_status) == 0) { $msg .= $text['message-required']." ".$text['label-fax_status']."<br>\n"; }
|
||||
//if (strlen($fax_retry_date) == 0) { $msg .= $text['message-required']." ".$text['label-fax_retry_date']."<br>\n"; }
|
||||
//if (strlen($fax_retry_count) == 0) { $msg .= $text['message-required']." ".$text['label-fax_retry_count']."<br>\n"; }
|
||||
//if (strlen($fax_accountcode) == 0) { $msg .= $text['message-required']." ".$text['label-fax_accountcode']."<br>\n"; }
|
||||
//if (strlen($fax_command) == 0) { $msg .= $text['message-required']." ".$text['label-fax_command']."<br>\n"; }
|
||||
if (strlen($msg) > 0 && strlen($_POST["persistformvar"]) == 0) {
|
||||
//if (empty($fax_uuid)) { $msg .= $text['message-required']." ".$text['label-fax_uuid']."<br>\n"; }
|
||||
if (empty($fax_date)) { $msg .= $text['message-required']." ".$text['label-fax_date']."<br>\n"; }
|
||||
if (empty($hostname)) { $msg .= $text['message-required']." ".$text['label-hostname']."<br>\n"; }
|
||||
//if (empty($fax_caller_id_name)) { $msg .= $text['message-required']." ".$text['label-fax_caller_id_name']."<br>\n"; }
|
||||
//if (empty($fax_caller_id_number)) { $msg .= $text['message-required']." ".$text['label-fax_caller_id_number']."<br>\n"; }
|
||||
if (empty($fax_number)) { $msg .= $text['message-required']." ".$text['label-fax_number']."<br>\n"; }
|
||||
//if (empty($fax_prefix)) { $msg .= $text['message-required']." ".$text['label-fax_prefix']."<br>\n"; }
|
||||
//if (empty($fax_email_address)) { $msg .= $text['message-required']." ".$text['label-fax_email_address']."<br>\n"; }
|
||||
if (empty($fax_file)) { $msg .= $text['message-required']." ".$text['label-fax_file']."<br>\n"; }
|
||||
if (empty($fax_status)) { $msg .= $text['message-required']." ".$text['label-fax_status']."<br>\n"; }
|
||||
//if (empty($fax_retry_date)) { $msg .= $text['message-required']." ".$text['label-fax_retry_date']."<br>\n"; }
|
||||
//if (empty($fax_retry_count)) { $msg .= $text['message-required']." ".$text['label-fax_retry_count']."<br>\n"; }
|
||||
//if (empty($fax_accountcode)) { $msg .= $text['message-required']." ".$text['label-fax_accountcode']."<br>\n"; }
|
||||
//if (empty($fax_command)) { $msg .= $text['message-required']." ".$text['label-fax_command']."<br>\n"; }
|
||||
if (!empty($msg) && empty($_POST["persistformvar"])) {
|
||||
require_once "resources/header.php";
|
||||
require_once "resources/persist_form_var.php";
|
||||
echo "<div align='center'>\n";
|
||||
|
||||
Reference in New Issue
Block a user