Welcome Guest, Not a member yet? Register   Sign In
session problem
#1

[eluser]shobekhan[/eluser]
I am getting an different session_id value each time I refresh the page any Idea why is this happening ? This is only happening on safari and IE and not on firefox


here is the complete code for controller

<?php
class Applications extends Controller {

function Applications()
{
parent::Controller();
$this->load->helper('url');
$this->load->model('function_model');
$this->load->library('session');
}

function index()
{

print $this->session->userdata('session_id');

}

}
?>
#2

[eluser]xwero[/eluser]
try autoloading the session library
#3

[eluser]Michael Wales[/eluser]
make sure the cookie settings in config.php are correct (if using the native CI session library)
#4

[eluser]shobekhan[/eluser]
This is the URL of the page it works fine on firefox but not on IE and Safari

http://www.rosenborgsolutions.com/mobile...plications

These are my config values

$config['sess_cookie_name'] = 'my_session_mobile';
$config['sess_expiration'] = 7200;
$config['sess_encrypt_cookie'] = FALSE;
$config['sess_use_database'] = TRUE;
$config['sess_table_name'] = 'ci_sessions';
$config['sess_match_ip'] = TRUE;
$config['sess_match_useragent'] = TRUE;
#5

[eluser]shobekhan[/eluser]
Found solutions to the problem

I downloaded the file from this URL

http://codeigniter.com/wiki/File:CI_1.5....ssion.zip/

and replaced it in the libraries folder and it worked
#6

[eluser]codelearn[/eluser]
Do you know what the difference in the two is?




Theme © iAndrew 2016 - Forum software by © MyBB