CXLVII. Unicode Functions

简介

Unicode Support.

警告

This extension is still in development and it isn't available to public yet.

需求

ICU 3.4 or later is required.

安装

First you should download and install ICU:

例子 1. install ICU on Unix

./configure --disable-threads --enable-extras --enable-icuio --enable-layout
make && make install

Then checkout latest PHP and configure it --with-icu-dir=<dir> option, where <dir> was the dir to where you installed ICU. You don't need to explicitly use this option if you install ICU to a standard location.

目录
unicode_encode -- Takes a unicode string and converts it to a string in the specified encoding

add a note add a note User Contributed Notes
Hugo Dworak (post at o2 dot pl)
23-Nov-2005 11:04
If you are really interested in PHP 6 and its Unicode support you should read:
http://www.zend.com/zend/week/php-unicode-design.txt
(and in general http://www.zend.com/zend/week/)
plus cvs/php6/README.UNICODE and cvs/php6/README.UNICODE-UPGRADES

After you compile PHP 6, make sure that you have enabled unicode_semantics = on in php.ini (an old PHP 5 configuration file will not do as it does not provide those new Unicode-related options).