From 0e924ceed7a71ac343e929270f3e529ecf85f2a5 Mon Sep 17 00:00:00 2001 From: Gabriel Potkány Date: Thu, 6 Nov 2014 11:35:46 +0100 Subject: Ability to pass array of language files to Language Library similar to Loader Library --- system/core/Lang.php | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'system/core/Lang.php') diff --git a/system/core/Lang.php b/system/core/Lang.php index 25d0af1ff..cac73c2e1 100644 --- a/system/core/Lang.php +++ b/system/core/Lang.php @@ -87,6 +87,14 @@ class CI_Lang { */ public function load($langfile, $idiom = '', $return = FALSE, $add_suffix = TRUE, $alt_path = '') { + if (is_array($langfile)) + { + foreach ($langfile as $value) + { + return $this->load($value, $idiom, $return, $add_suffix, $alt_path); + } + } + $langfile = str_replace('.php', '', $langfile); if ($add_suffix === TRUE) -- cgit v1.2.3-24-g4f1b