Bitrix API

Language

Context may have special language.

Table of Contents

Methods

__construct()  : mixed
getAvailable()  : array<string|int, mixed>
getCode()  : string
Return code of language.
getName()  : string

Methods

__construct()

public __construct(string $code) : mixed
Parameters
$code : string
  • one of available codes. If incorrect code - will be used current B24 localization

getAvailable()

public static getAvailable([string|null $langCode = null ]) : array<string|int, mixed>
Parameters
$langCode : string|null = null

Get all available context languages with names (in current B24 localization) ** @return array - code => name

Return values
array<string|int, mixed>

getCode()

Return code of language.

public getCode() : string

Most codes from ISO 639-1 standart, some from ISO 639-2, and some - Bitrix localization standart

Return values
string

getName()

public getName([string|null $langCode = null ]) : string
Parameters
$langCode : string|null = null

Return language name in current B24 localization ** @return string

Return values
string

        
On this page

Search results