PHP Class yii\helpers\Inflector

Do not use BaseInflector. Use Inflector instead.
Since: 2.0
Author: Antonio Ramirez ([email protected])
Author: Alexander Makarov ([email protected])
Inheritance: extends BaseInflector
Show file Open project: infoweb-internet-solutions/yii2-cms Class Usage Examples

Public Properties

Property Type Description
$transliteration fallback map for transliteration used by Inflector::transliterate when intl isn't available.

Public Methods

Method Description
transliterate ( string $string, string | Transliterator $transliterator = null ) : string Returns transliterated version of a string.

Method Details

transliterate() public static method

If intl extension isn't available uses fallback that converts latin characters only and removes the rest. You may customize characters map via $transliteration property of the helper.
public static transliterate ( string $string, string | Transliterator $transliterator = null ) : string
$string string input string
$transliterator string | Transliterator either a [[Transliterator]] or a string from which a [[Transliterator]] can be built.
return string

Property Details

$transliteration public static property

fallback map for transliteration used by Inflector::transliterate when intl isn't available.
public static $transliteration