Daniel Buhai
Daniel Buhai

Reputation: 125

php session variables problem in Firefox

I set several php session variables in an initial php file. In all other ajax loaded php files the value of those session variables is updated only after refreshing the page. This happens only in Firefox. Does anyone know what may cause this to happen? In IE everything works fine.

Upvotes: 3

Views: 7681

Answers (1)

Daniel Buhai
Daniel Buhai

Reputation: 125

I found a solution. There was a cache issue. Write:

header("Cache-Control: no-cache");
header("Pragma: no-cache");

after

session_start();

in all your conventional scripts.

Upvotes: 4

Related Questions