mbstring extension
- Enable extension in
php.ini
file:
extension=mbstring
- Get Unicode code point of character:
<?php
$character = '™';
$code = sprintf('U+%04X', mb_ord($character));
echo $code; // U+2122
php.ini
file:extension=mbstring
<?php
$character = '™';
$code = sprintf('U+%04X', mb_ord($character));
echo $code; // U+2122
Leave a Comment
Cancel reply