diff options
Diffstat (limited to 'modules/gallery/helpers')
-rw-r--r-- | modules/gallery/helpers/locale.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/gallery/helpers/locale.php b/modules/gallery/helpers/locale.php index c176dcc6..9783a53a 100644 --- a/modules/gallery/helpers/locale.php +++ b/modules/gallery/helpers/locale.php @@ -114,7 +114,9 @@ class locale_Core { return self::$locales["$locale"]; } - static function is_rtl($locale) { - return in_array($locale, array("he_IL", "fa_IR", "ar_SA")); + static function is_rtl($locale=null) { + $locale or $locale = I18n::instance()->locale(); + list ($language, $territory) = explode('_', $locale . "_"); + return in_array($language, array("he", "fa", "ar")); } }
\ No newline at end of file |