What about this: https://github.com/symfony/polyfill
or simply:
if (!function_exists("mb_trim"))
{
function mb_trim($str)
{
return preg_replace("/^\s+|\s+$/u", '', $str);
};
};
Vote up if you agree.🤓