Welcome Guest, Not a member yet? Register   Sign In
unset session userdata array
#3

(03-10-2015, 08:02 AM)CroNiX Wrote: Are you talking about having it affect the current user, all logged in users, or a different user who is logged in?

Hi, Thanks for reply I think I have found what best way is.


PHP Code:
public function edit() {

$this->load->model('admin/user/model_user_group');

if (
$this->input->server('REQUEST_METHOD') == 'POST') {

$this->model_user_group->editUserGroup($this->uri->segment(4), $this->input->post());

$user_group_query $this->db->query("SELECT permission FROM " $this->CI->db->dbprefix "user_group 
WHERE user_group_id = '" 
. (int)$this->session->userdata('user_group_id') . "'");

$permissions unserialize($user_group_query->row('permission'));

$this->session->set_userdata($permissions);

redirect('admin/users_group');
            
}

$this->getForm();


There's only one rule - please don't tell anyone to go and read the manual.  Sometimes the manual just SUCKS!
Reply


Messages In This Thread
unset session userdata array - by wolfgang1983 - 03-10-2015, 07:53 AM
RE: unset session userdata array - by CroNiX - 03-10-2015, 08:02 AM
RE: unset session userdata array - by wolfgang1983 - 03-10-2015, 09:43 PM



Theme © iAndrew 2016 - Forum software by © MyBB