Converting these types of unicode to UTF8 in PHP
php, unicode, utf-8
Solution
None of the other answers work perfectly as is. I've combined them together and my addition results in this one:
$replacedString = preg_replace("/\\\\u([0-9abcdef]{4})/", "&#x$1;", $originalString);
$unicodeString = mb_convert_encoding($replacedString, 'UTF-8', 'HTML-ENTITIES');
This one definitely does work :)
Problem
I am trying to convert this in to readable UTF8 text in PHP ``` Tel Aviv-Yafo (Hebrew: \u05ea\u05b5\u05bc\u05dc\u05be\u05d0\u05b8\u05d1\u05b4\u05d9\u05d1-\u05d9\u05b8\u05e4\u05d5\u05b9; Arabic: \u062a\u0644 \u0623\u0628\u064a\u0628\u200e, Tall \u02bcAb\u012bb), usually called Tel Aviv ``` Any ideas on how to do so? Tried several methods online, but couldn't find one. In this case I have unicode in Hebrew and Arabic