My code works for set new session and get them. But sessions which are already generated in CI are not getting access outside .
<?php
ob_start();
include('index.php');
ob_end_clean();
$CI =& get_instance();
$CI->load->library('session'); //if it's not autoloaded in your CI setup
echo '<pre>'; print_r($CI->session->all_userdata()); /* not working .not showing CI sessions*/
echo "Ff";$CI->session->set_userdata('d','gg'); /* working for setting new session */
echo $CI->session->userdata('d'); $CI->session->userdata('name'); /* working for getting new session */
?>