Transliterator Helper transliterates UTF-8 encoded text to US-ASCII
Adapted for PHP 5.3 by koftikes.
The preferred way to install this extension is through composer.
Either run
composer require sbs/transliterator-helper
or add
"sbs/transliterator-helper": "^1.0"
to the require section of your application's composer.json
file.
Pass to the method process()
the UTF-8 encoded string you wish to transliterate:
use dosamigos\yii\helpers\TransliteratorHelper;
// will echo AAAAAAAECEEEEIIIIDNOOOOOUUUUYssaaaaaaaeceeeeiiiidnooooouuuuyy
TransliteratorHelper::process('ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöùúûüýÿ', '', 'en'));