PHP version upgrade from 5.6 to 7.4 causing issue for mbstring.func_overload = 6

673 Views Asked by At

I am upgrading the PHP version from 5.6 to 7.4 and it is causing an error related to the php.ini setting:

mbstring.func_overload = 6

The error is: PHP Deprecated: The mbstring.func_overload directive is deprecated in Unknown on line 0

This setting was used in previous version to handle multi-byte character issues.

We need to prevent the multi-byte character issues in future also.

What is the solution for this ?

1

There are 1 best solutions below

0
Zoli Szabó On

Don't use it. It is deprecated since PHP 7.2 and removed in PHP 8. https://www.php.net/manual/en/mbstring.configuration.php#ini.mbstring.func-overload

If you want a future-proof solution, replace them all with the mb_ version of the functions.