note 56616 added to function.mb-convert-encoding
| From: | StephanvanderFeest at osu1 dot php dot net | Date: | Fri, 09 Sep 2005 10:50:54 +0000 |
| Subject: | note 56616 added to function.mb-convert-encoding | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-94957@lists.php.net to get a copy of this message | ||
Here's a tip for anyone using Flash and PHP for storing HTML output submitted from a Flash text
field in a database or whatever.
Flash submits its HTML special characters in UTF-8, so you can use the following function to convert
those into HTML entity characters:
function utf8html($utf8str)
{
return htmlentities(mb_convert_encoding($utf8str,"ISO-8859-1","UTF-8"));
}
----
Manual Page -- http://www.php.net/manual/en/function.mb-convert-encoding.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+56616
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes&reason=non-english
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56616&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+56616&report=yes
Search -- http://master.php.net/manage/user-notes.php