Welcome Guest, Not a member yet? Register   Sign In
Returning to update form after validation
#19

[eluser]flaky[/eluser]
found the little bug
in the controller you have it like this
Code:
else
        {
            $this->users_model->update_user($data);
            $this->update_admin_form($data);
        }

while in the model

Code:
function update_user($user_id)
    {
        $this->db->where('userid', $user_id );
        $this->db->update('pp_users', $data);    
        return;
    }

change them to this


in the controller
Code:
else
        {
            $this->users_model->update_user($this->uri->segment(4), $data);
            $this->update_admin_form($data);
        }


in the model
Code:
function update_user($user_id, $data)
    {
        $this->db->where('userid', $user_id );
        $this->db->update('pp_users', $data);    
        return;
    }


Messages In This Thread
Returning to update form after validation - by El Forum - 01-07-2010, 05:46 AM
Returning to update form after validation - by El Forum - 01-07-2010, 06:34 AM
Returning to update form after validation - by El Forum - 01-07-2010, 07:06 AM
Returning to update form after validation - by El Forum - 01-07-2010, 07:18 AM
Returning to update form after validation - by El Forum - 01-07-2010, 07:27 AM
Returning to update form after validation - by El Forum - 01-07-2010, 07:42 AM
Returning to update form after validation - by El Forum - 01-07-2010, 07:48 AM
Returning to update form after validation - by El Forum - 01-07-2010, 08:01 AM
Returning to update form after validation - by El Forum - 01-07-2010, 08:10 AM
Returning to update form after validation - by El Forum - 01-07-2010, 08:12 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:14 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:24 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:29 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:32 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:42 AM
Returning to update form after validation - by El Forum - 01-07-2010, 10:59 AM
Returning to update form after validation - by El Forum - 01-07-2010, 11:40 AM
Returning to update form after validation - by El Forum - 01-07-2010, 02:04 PM
Returning to update form after validation - by El Forum - 01-07-2010, 02:10 PM
Returning to update form after validation - by El Forum - 01-08-2010, 03:41 AM
Returning to update form after validation - by El Forum - 01-08-2010, 05:27 AM
Returning to update form after validation - by El Forum - 01-08-2010, 05:31 AM



Theme © iAndrew 2016 - Forum software by © MyBB