Is there an easier way than
foreach($_POST as $x=>$y){
$arr[$x] = $this->input->get_post($y, TRUE);
}
to just have the entire $_POST array cleaned with CI’s XSS filter. Looking at the input library it seems though get_post() only accepts an individual variable rather than being able to clean the entire array and then return the array back.
Not sure if you want it globally, but if you do… from ze manual:
If you want the filter to run automatically every time it encounters POST or COOKIE data you can enable it by opening your application/config/config.php file and setting this: