• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
callback - looping or happening twice! Please help!!!

I am running the callback and originally it was sending an mail which started arriving twice. Simplfying it down... it appears to only be occuring through the callback i am making... not sure why, but hopefully someone can spot the obvious i am missing!!!

function forgotten()
        $fields = array('email' => 'Email Address');
        $rules = array('email' => 'required|callback_email');
        $this->validation->set_error_delimiters('<div class="error">', '</div>');
        if ($this->validation->run() == FALSE)
        else if ($this->validation->run() == TRUE)
            $this->session->set_flashdata('message', 'success and redirected');

sorry being a spanner!!! i am running and if and else if, therefore doing the validation twice and i did not see it... fool...

Having a spanner in the forums is better than all the loose nuts we normally get. :lol:

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.