note 103298 deleted from function.mb-convert-encoding by danbrown
| From: | danbrown@php.net | Date: | Wed, 06 Apr 2011 13:45:52 +0000 |
| Subject: | note 103298 deleted from function.mb-convert-encoding by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-178560@lists.php.net to get a copy of this message | ||
Note Submitter: alvaro at demogracia dot com
----
You can use the HTML-ENTITIES encoding to insert arbitrary Unicode characters, e.g. "U+25B6
(BLACK RIGHT-POINTING TRIANGLE)":
<?php
$triangle = mb_detect_order(mb_convert_encoding('▶', 'UTF-8',
'HTML-ENTITIES'));
?>
Be aware though that older PHP versions do not seem to support hexadecimal notation (▶).
In such case, use decimal notation (▶):
<?php
$triangle = mb_detect_order(mb_convert_encoding('▶', 'UTF-8',
'HTML-ENTITIES'));
?>