The Symfony Polyfill / Intl ICU Component

This component provides a native PHP implementation of several Intlfunctions and classes to users who run PHP versions without the intlextension.

Installation

  1. $ composer require symfony/polyfill-intl-icu

Note

If you install this component outside of a Symfony application, you mustrequire the vendor/autoload.php file in your code to enable the classautoloading mechanism provided by Composer. Readthis article for more details.

Usage

Once this component is installed in your application, you can use the followingclasses and functions, no matter if the PHP intl extension is installed ornot in your server.

Provided Classes

Provided Functions

Symfony provides more polyfills for other classes and functions related tothe Intl PHP extension:polyfill-intl-grapheme,polyfill-intl-idn,polyfill-intl-messageformatter,and polyfill-intl-normalizer.