CLXVIII. Unicode Functions

Introductie

Unicode Support.

Waarschuwing

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

Afhankelijkheden

ICU 3.4 or later is required.

Installatie

First you should download and install ICU:

Voorbeeld 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.

Configuratie tijdens scriptuitvoer

Het gedrag van deze functies wordt beïnvloed vanuit php.ini.

Tabel 1. Unicode Configuration Options

NameDefaultChangeableChangelog
unicode.fallback_encodingNULLPHP_INI_ALLAvailable since PHP 6.0.0.
unicode.from_error_mode"2"PHP_INI_ALLAvailable since PHP 6.0.0.
unicode.from_error_subst_char"3f"PHP_INI_ALLAvailable since PHP 6.0.0.
unicode.http_input_encodingNULLPHP_INI_ALLAvailable since PHP 6.0.0.
unicode.output_encodingNULLPHP_INI_ALLAvailable since PHP 6.0.0.
unicode.runtime_encodingNULLPHP_INI_ALLAvailable since PHP 6.0.0.
unicode.script_encodingNULLPHP_INI_ALLAvailable since PHP 6.0.0.
unicode.semanticsoffPHP_INI_SYSTEMAvailable since PHP 6.0.0.
For further details and definitions of the PHP_INI_* constants, see the Bijlage I.

Here's a short explanation of the configuration directives.

unicode.output_encoding string

Default encoding for output.

Voorgedefinieerde constanten

Deze constanten worden gedefinieerd door deze extensie, en zullen alleen beschikbaar zijn als de extensie met PHP is meegecompileerd, of als deze dynamisch is geladen vanuit een script.

Tabel 2.

constantvaluedescription
U_INVALID_STOP0stop at first invalid character
U_INVALID_SKIP1skip invalid characters
U_INVALID_SUBSTITUTE2replace invalid characters
U_INVALID_ESCAPE3escape invalid characters

Inhoudsopgave
unicode_encode -- Set encoding of a unicode string
unicode_semantics -- Check whether unicode semantics is enabled