Quantcast
Channel: Joomla! Forum - community, help and support
Viewing all articles
Browse latest Browse all 2039

Joomla! 5.x Coding • Problems with null parameters in PHP8.3 and Joomla5

$
0
0
Hi,

I get these errors when viewing categories using Joomla5.0.3 with PHP8.3:

Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /.../plugins/system/t4/src/t4/T4.php on line 188

Deprecated: mb_strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /.../libraries/vendor/joomla/string/src/phputf8/mbstring/core.php on line 44

Deprecated: mb_strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /.../libraries/vendor/joomla/string/src/phputf8/mbstring/core.php on line 44


I corrected them by:

in core.php:

by changing the line 44:

return mb_strpos($str, $search);

with:

if ( $str == null ) return false;
return mb_strpos($str, $search);


and, in T4.php:

by adding:

if ( $buffer != null )

in front of the following lines starting from 188th row in T4.php

$buffer = str_replace(array(...

and subsequent lines starting with if (preg_match...

Statistics: Posted by ilkerf — Tue Feb 27, 2024 10:58 am



Viewing all articles
Browse latest Browse all 2039

Trending Articles