Fix PHP8 deprecied param
This commit is contained in:
parent
f8291f593d
commit
0220dc0fe2
1 changed files with 1 additions and 11 deletions
12
index.php
12
index.php
|
@ -41,17 +41,7 @@ $GLOBALS['config']['log'] = true;
|
||||||
if (file_exists('cache/config/options.php')) {
|
if (file_exists('cache/config/options.php')) {
|
||||||
require 'cache/config/options.php';
|
require 'cache/config/options.php';
|
||||||
}
|
}
|
||||||
if (get_magic_quotes_gpc()) {
|
|
||||||
function stripslashes_deep($value)
|
|
||||||
{
|
|
||||||
$value = is_array($value) ? array_map('stripslashes_deep', $value) : stripslashes($value);
|
|
||||||
return $value;
|
|
||||||
}
|
|
||||||
|
|
||||||
$_POST = array_map('stripslashes_deep', $_POST);
|
|
||||||
$_GET = array_map('stripslashes_deep', $_GET);
|
|
||||||
$_COOKIE = array_map('stripslashes_deep', $_COOKIE);
|
|
||||||
}
|
|
||||||
if (!empty($_POST)) {
|
if (!empty($_POST)) {
|
||||||
$ui = $_POST;
|
$ui = $_POST;
|
||||||
$ui['request'] = 'form';
|
$ui['request'] = 'form';
|
||||||
|
@ -200,7 +190,7 @@ function makeQueueFile($url, $hashUrl, $width, $size, $renderType)
|
||||||
function testValidUrl($url)
|
function testValidUrl($url)
|
||||||
{
|
{
|
||||||
$url = trim($url);
|
$url = trim($url);
|
||||||
if (filter_var($url, FILTER_VALIDATE_URL, FILTER_FLAG_SCHEME_REQUIRED | FILTER_FLAG_HOST_REQUIRED)) {
|
if (filter_var($url, FILTER_VALIDATE_URL)) {
|
||||||
$url = parse_url($url);
|
$url = parse_url($url);
|
||||||
if (!in_array($url['scheme'], array(
|
if (!in_array($url['scheme'], array(
|
||||||
'http',
|
'http',
|
||||||
|
|
Loading…
Reference in a new issue