Locale::addLikelySubtags
PHP Manual
PHP Manual»Locale»Locale::addLikelySubtags

Locale::addLikelySubtags

locale_add_likely_subtags

(No version information available, might only be in Git)

Locale::addLikelySubtags -- locale_add_likely_subtags — Add likely subtags to a locale

说明

面向对象风格

public static function Locale::addLikelySubtags(string $locale): string|false

过程化风格

function locale_add_likely_subtags(string $locale): string|false

Expands a locale tag by adding likely subtags based on the ICU locale data. For example, en becomes en_Latn_US.

参数

locale

The locale to expand.

返回值

Returns the locale with likely subtags added, or false on failure.

错误/异常

Throws a ValueError when the locale argument contains null bytes.

参见

To Top