Re: Convert fake Unicode to real UTF-8
| From: | Minuk Choi | Date: | Thu, 03 Nov 2005 20:54:13 +0000 |
| Subject: | Re: Convert fake Unicode to real UTF-8 | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-225069@lists.php.net to get a copy of this message | ||
Have you tried feeding that through htmlentities()?
e.g. echo htmlentities("Га");
see if that outputs what you want on the page.
-Mk
Andreas Jakl wrote:
I've been searching for quite some time now and tried several functions, but didn't find a solution. I hope somebody can point me in the right direction. The problem: Russian text is entered through a web form. It's a rather badly administrated external webserver with old versions of everything, so I can not set the table to UTF-8. In the MySQL-Table the text gets converted to something like "Га" as an ASCII text. Using PHP I need to get the text out into a plain text file, as a real UTF-8 string. How can I convert this? All the conversion methods from PHP that I tried failed, as the text seems to really consist of the individual ASCII chars like "&", "#". Therefore, a normal to-unicode-conversion doesn't change anything. Thanks in advance, Andreas Jakl