Welcome Guest, Not a member yet? Register   Sign In
Rather Newish to OOP, Controller question
#3

(This post was last modified: 05-19-2016, 11:40 PM by BamaStangGuy.)

Hi Wouter60,

Here is join method which loads the Join view. Join view submits to the enter method and enter method reloads the join view.

PHP Code:
   public function join($project_id) {
 
       if ($this->require_min_level(1)) {
 
           if ($data['project']['active'] == 1) {
 
               $this->load->model('project_model');
 
               $data['pool'] = $this->project_model->get_project($project_id);
 
               $data['entries'] = $this->project_model->get_entries($project_id);
 
               $this->load->model('validation_callables');
 
               $this->load->library('form_validation');
 
               $this->load->view('includes/nav');
 
               $this->load->view('join'$data);
 
               $this->load->view('includes/footer');
 
           } else {
 
               redirect('project/');
 
           }
 
       }
 
   

What I want to do is that after they are entered into the project, load up the join view again and present them information about their entry or errors that might have happened.
Reply


Messages In This Thread
RE: Rather Newish to OOP, Controller question - by BamaStangGuy - 05-19-2016, 11:37 PM



Theme © iAndrew 2016 - Forum software by © MyBB