Encode string into unicode using PHP

180 Views Asked by At

I'm trying to encode a string into unicode with:

$text = 'Hello  World';
echo mb_convert_encoding($text, "UTF-8");

Running that should convert the  character, but it is still displayed when I echo it. Why?

0

There are 0 best solutions below