$type = $this->input->post('type');
$crud = new grocery_CRUD();
$crud->set_table('employees');
switch($type){
case 1:
$crud->where('jobTitle','Sales Rep');
$output = $crud->render();
break;
case 2:
$crud->where('jobTitle','VP Sales');
$output = $crud->render();
break;
case 3:
$crud->where('jobTitle','Sales Manager');
$output = $crud->render();
break;
default:
$output = $crud->render();
break;
}
$this->_example_output($output);
Show certain data with where
- Single Page
Posted 03 December 2012 - 02:42 AM
Posted 03 December 2012 - 13:49 PM
Posted 03 December 2012 - 13:57 PM