get_available_languages WordPress Filter Hook

The get_available_languages Wordpress hook allows you to determine which languages are available on your site. This can be useful if you want to create a multilingual site or if you want to limit access to certain languages.

apply_filters( 'get_available_languages', string[] $languages, string $dir ) #

Filters the list of available language codes.


Parameters

$languages

(string[])An array of available language codes.

$dir

(string)The directory where the language files were found.


Top ↑

Source

File: wp-includes/l10n.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
4.7.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.