use session in codeigniter code example
Example: print all session in codeigniter
print_r($this->session->userdata);
or
print_r($this->session->all_userdata());
print_r($this->session->userdata);
or
print_r($this->session->all_userdata());