Fix all PHP 8 deprecated/removed function usage across the repository
Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/209fe796-9a38-47c1-a6b7-992ce11d038b Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
This commit is contained in:
parent
73319ffeed
commit
c0bd0a0bb5
30 changed files with 198 additions and 471 deletions
|
|
@ -2953,12 +2953,12 @@ function checkEmailAddress($email) {
|
|||
// Returns true for valid email addresses, false for non-valid email addresses
|
||||
// --------------
|
||||
|
||||
if (eregi( "^" .
|
||||
if (preg_match( "/^" .
|
||||
"[a-z0-9]+([_\.-][a-z0-9]+)*" . //user
|
||||
"@" .
|
||||
"([a-z0-9]+([\.-][a-z0-9]+)*)+" . //domain
|
||||
"\\.[a-z]{2,}" . //sld, tld
|
||||
"$", $email, $regs)) { return true; }
|
||||
"$/i", $email, $regs)) { return true; }
|
||||
else { return false; }
|
||||
|
||||
} // end checkEmailAddress
|
||||
|
|
@ -3326,12 +3326,12 @@ $AttmFiles ... array containing the filenames to attach like array("file1","file
|
|||
}
|
||||
|
||||
// Check if the To email address is valid
|
||||
if (!eregi( "^" .
|
||||
if (!preg_match( "/^" .
|
||||
"[a-zA-Z0-9]+([_\.-][a-zA-Z0-9]+)*" . //user
|
||||
"@" .
|
||||
"([a-zA-Z0-9]+([\.-][a-zA-Z0-9]+)*)+" . //domain
|
||||
"\\.[a-zA-Z]{2,}" . //sld, tld
|
||||
"$", $To, $regs)) {
|
||||
"$/i", $To, $regs)) {
|
||||
$errormessage = __("The email address you have entered (%1\$s) does not seem to be valid.<br />Please enter an address in the format <b>username@domain.com</b>", $To);
|
||||
setErrorVars(false, $errormessage, debug_backtrace(), __FILE__, __LINE__);
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue