Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- function process(){
- $action = $this->input->post('action');
- $pass_through = array(
- 'update_main', 'update_alt', 'update_rank',
- 'delete_main', 'delete_alt', 'delete_rank',
- 'insert_main', 'insert_alt', 'insert_rank'
- );
- if(in_array($action, $pass_through)){
- $action = '_'.$action;
- $this->$action();
- } else{
- // Error.
- }
- }
- ?>
Add Comment
Please, Sign In to add comment