[eluser]opel[/eluser]
I know Codeigniter has the ability to make custom form validation in controllers as callbacks but is there a way to make up global custom validation functions ?
What I am trying to do is use a function I created as a plugin to filter some $_POST data. Instead of me having to manually do something such as :
Code:
$_POST['name'] = plugin_function($this->input->post('name'));
I would like to have something like :
Code:
$this->form_validation->set_rules('name', 'name', 'trim|plugin_function|xss_clean');
is this possible without having to put callback_plugin_function in every controller ?