diff options
author | Ahmad Anbar <aanbar@gmail.com> | 2014-12-02 09:04:46 +0100 |
---|---|---|
committer | Ahmad Anbar <aanbar@gmail.com> | 2014-12-02 09:04:46 +0100 |
commit | 89432af4adb4011ad8aa5252838dc76a3a5acec7 (patch) | |
tree | 60f0f63c919f58b50691f672789f8d156d1ad13b /system | |
parent | 5078eb5062457c1eef2fab0c58fa27f249616b78 (diff) |
Allow pulling multiple get/post ...etc at once
Diffstat (limited to 'system')
-rw-r--r-- | system/core/Input.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/system/core/Input.php b/system/core/Input.php index 81555df9a..0dcb6f425 100644 --- a/system/core/Input.php +++ b/system/core/Input.php @@ -168,6 +168,18 @@ class CI_Input { return $output; } + // allow fetching multiple keys at once + if (is_array($index)) + { + $output = array(); + foreach($index as $var) + { + $output[$var] = $this->_fetch_from_array($array, $var, $xss_clean); + } + + return $output; + } + is_bool($xss_clean) OR $xss_clean = $this->_enable_xss; if (isset($array[$index])) |