Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Session variables expiring

0 views
Skip to first unread message

mohadi

unread,
Jul 21, 2007, 11:26:07 AM7/21/07
to
I have an application with session variables set up as in the code below.
It appears that I am losing my session variables (very intermittent) since I
am getting kicked back to the login page.
I have noticed that it happens more often when using form buttons to navigate
rather than regular links. Such as:

<a href="mypage.cfm">My Page</a>: works fine

<input type="button" name="Menu" value="Admin Menu"
onclick="MM_goToURL('parent','MyPage.cfm');return document.MM_returnValue">:
does not work some of the time

Does anyone have any ideas why this should happen especially since I have
other application with similar set up working fine?

P.S. My client want to keep the look (buttons) as they are and does not want
to change them to HTML links. This happnes on CFMX6.1 and CFMX7.0

Application.cfm:

<cfapplication name="Symlin" clientmanagement="Yes" sessionmanagement="Yes"
sessiontimeout="#CreateTimeSpan(0,0,20,0)#"
applicationtimeout="#CreateTimeSpan(0,12,0,0)#">

<cflock timeout=10 scope="session" type="readonly">
<cfif not IsDefined("session.UserId")>
<cflocation url="Login.cfm" addtoken="No">
</cfif>
</cflock>

Michael

unread,
Jul 31, 2007, 10:09:13 PM7/31/07
to
It doesn't matter if a page is requested using a link or form. It is merely
the request that restarts the session timer.

Make sure you don't have multiple Application.cfc/.cfm pages in subdirectories
that may have different session timeout values.

Also, check for any code that may be removing cfid/cftoken/jsessionid cookies,
thereby, killing the session.

0 new messages