Re: UNICODE in PHP
| From: | Rui Hirokawa | Date: | Sun, 21 Oct 2001 00:21:24 +0000 |
| Subject: | Re: UNICODE in PHP | ||
| References: | 1 | Groups: | php.i18n |
| Request: | Send a blank email to php-i18n+get-207@lists.php.net to get a copy of this message | ||
Hi,
On Fri, 19 Oct 2001 20:01:38 +0200
"Per" <per@mobilehits.com> wrote:
> Hi,
>
> I would be most interested in knowing the current status of multi-byte
> character handling in PHP, and also some kind of forecast of when it is
> expected to work in a stable manner. Currently, there is an experimental
> module for this at
> http://www.php.net/manual/en/ref.mbstring.php. How stable
> is it? Does it support all the "normal" string functions?
I think mbstring is fairly stable now.
I already removed ext/mbstring/EXPERIMENTAL from CVS tree.
It doesn't support all string functions, but,
it is very useful to build multi-byte enabled Web applications.
mbstring has some multi-byte string handling functions
shown in below,
- character encoding conversion between Unicode and
japanese encoding (EUC-JP,Shift_JIS,ISO-2022-JP), ISO-8859-1..9
- some string functions with multi-byte string compatibility
strlen, substr, strpos, etc.
- POST/GET/Cookie input character encoding detection and conversion to
internal encoding.
- output character encoding convertion.
mbstring uses gerenal implementaion for multi-language support,
but, currently it supports only japanese multi-byte encoding
and Unicode, and some single byte encoding.
PHP 4.0.6 is the first version of PHP 4 which has multi-byte support.
In japan, almost PHP users are using PHP 4.0.6 with mbstring
or japanese localized version of PHP 3 (called PHP-3.0.18-i18n).
Limitations of mbstring are,
- mbstring doesn't support multi-byte regex.
(You can use mbregex extension.)
- mbstring doesn't support all string functions.
Native unicode support for PHP 4 is neccesary to make
php-i18n.
I hope Zend Engine 2/ PHP 5 (?) will support
this functionality.
--
-----------------------------------------------------
Rui Hirokawa <rui_hirokawa@ybb.ne.jp>
<hirokawa@php.net>