Jump to content

Not show name some Products ps1.6.1.5


mehran

Recommended Posts

I finaly see this code problem  with some characters:

/classes/Tools.php  line 1556

    public static function truncate($str, $max_length, $suffix = '...')
    {
        if (Tools::strlen($str) <= $max_length) {
            return $str;
        }
        $str = utf8_decode($str);
        return (utf8_encode(substr($str, 0, $max_length - Tools::strlen($suffix)).$suffix));
    }

 

this code does not work correctly

For example 141 no problem but 14.1  or 12*12 has problem  but 1212 no problem

My php is 5.5.3

this is a bug?

Edited by mehran (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...