wpcf7_is_rtl()CF7 1.0

Returns true if the given locale is an RTL language.

Хуков нет.

Возвращает

null. Ничего (null).

Использование

wpcf7_is_rtl( $locale );
$locale **
-
По умолчанию: ''

Код wpcf7_is_rtl() CF7 5.9.3

function wpcf7_is_rtl( $locale = '' ) {
	static $rtl_locales = array(
		'ar' => 'Arabic',
		'ary' => 'Moroccan Arabic',
		'azb' => 'South Azerbaijani',
		'fa_IR' => 'Persian',
		'haz' => 'Hazaragi',
		'he_IL' => 'Hebrew',
		'ps' => 'Pashto',
		'ug_CN' => 'Uighur',
	);

	if ( empty( $locale )
	and function_exists( 'is_rtl' ) ) {
		return is_rtl();
	}

	if ( empty( $locale ) ) {
		$locale = determine_locale();
	}

	return isset( $rtl_locales[$locale] );
}