We have several sites that use sessions to store data. They work perfectly. However, I just created a new site, and its session is reset every time a page loads. So, I can't store the user login.
We're still using application.cfm. In that I have only this:
<CFAPPLICATION
NAME="TestName1"
APPLICATIONTIMEOUT="#CreateTimeSpan(0,8,0,0)#"
SESSIONTIMEOUT="#CreateTimeSpan(0,8,0,0)#"
sessionmanagement="yes"
scriptprotect="all"
setclientcookies="yes">
In a file in the same directory as application.cfm, I have a file called sessiontest.cfm with only this:
<cfdump var="#session#" label="SESSION">
<br /><br />
<cfdump var="#cookie#" label="COOKIE">
On the first run, this is what I saw in the browser loading sessiontest.cfm:
On refesh, this is what I saw:
I can refresh in rapid succession and each refresh starts a new session. The site uses an SSL cert and is run on IIS7, although we have others with the same setup that are working fine, so I'm not sure that would make a difference. Oh, and to make it worse, this doesn't seem to happen for everybody.
Any thoughts what we can change or check to get sessions to stick?