recently in my error logs i am getting this error :

[26-Apr-2023 08:09:25 UTC] PHP Parse error: syntax error, unexpected '=' in /home/j730lrwtovb3/public_html/support/include/class.forms.php on line 4043

this is what on line 4043 :


$config['size'] ??= $cfg->getMaxFileSize();
$types = self::getFileTypes();
$mimetypes = array();
$extensions = array();
if (isset($config['mimetypes']) && is_array($config['mimetypes'])) {
foreach ($config['mimetypes'] as $type=>$desc) {
foreach ($
types[$type]['types'] as $mime=>$exts) {
$mimetypes[$mime] = true;
if (is_array($exts))
foreach ($exts as $ext)
$extensions['.'.$ext] = true;
}
}
}
can someone please help me to solve this problem

abdullahkh

Sounds like you are not running the appropriate PHP version. For 1.17.x you need to be running PHP 8.0 or 8.1.

Cheers.

    abdullahkh

    ??= is a compound null coalescing assignment operator introduced with PHP 7.0. You need to contact your host as this should be available in PHP >= 7.0.

    Cheers.

      6 days later

      KevinTheJedi
      sorry i didnt understand what i should do
      should i change something from the files or do i need to contact my host to change it for me ?

        abdullahkh

        Need to ask your host why ??= doesn't work in your instance when it was introduced with PHP 7. ??= should be valid and working so not sure why your instance is complaining about it.

        Cheers.

          abdullahkh

          /home/j730lrwtovb3/public_html/support/include/class.forms.php on line 4043

          this is what on line 4043 :

          $config['size'] ??= $cfg->getMaxFileSize();

            Write a Reply...