$data2 = array( 'session_hotel_destination' => $destination, 'session_hotel_start_date' => $start_date, 'session_hotel_departure_date' => $end_date, 'session_hotel_night_num' => $night_num, 'session_hotel_adult' => $adult, 'session_hotel_child' => $child ); $this->session->set_userdata('session_hotel_reservation', $data2); $session_hotel_reservation = $this->session->userdata('session_hotel_reservation'); echo $session_hotel_reservation['session_hotel_destination']; $this->session->sess_destroy(); $this->session->unset_userdata($array_items); $this->session->unset_userdata('session_update_status');