View file File name : Property_image.php Content :<?php class Property_image extends CI_Controller{ public function index(){ $this->load->model('Property_image_model'); $data=$this->Property_image_model->get_images(); $this->load->view('Property_image_list',["test"=>$data]); } public function create_image(){ $this->load->view('header'); $this->load->view('Create_image_form'); $this->load->view('footer'); } public function add_image(){ $property_id=$this->input->post('property_id'); $image_1=$this->input->post('image_1'); $image_2=$this->input->post('image_2'); $image_3=$this->input->post('image_3'); $image_4=$this->input->post('image_4'); $image_5=$this->input->post('image_5'); $updated_by=$this->input->post('updated_by'); $this->load->model('Property_image_model'); $id=$this->Property_image_model->add_images($property_id,$image_1,$image_2,$image_3,$image_4,$image_5,$updated_by); redirect('Property_image/index'); } public function signout(){ session_destroy(); redirect('/User_login'); } public function logout(){ session_destroy(); redirect('/User_login'); } } ?>