I’m using the substr() function to limit the characters in strings. but sometimes, the output text contains some obscure characters and Question marks etc…
the text which is “substred” is already UTF8 encoded, and NOT in html entities to make like this problem.
Thanks
Because you are cutting your characters into half.
Use
mb_substrfor multibyte character encodings like UTF-8.substrjust counts bytes whilemb_substrcounts characters.