Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Keep losing Session variables

Status
Not open for further replies.

jedel

Programmer
Jan 11, 2003
430
AU
Hi all,

I have a site with a number of access databases, each of them having a login table so that each department is able to log into their own area and manage the content of the site.

The login page works fine. I have a session variable that records to the user ID and and this shows on each page that the user goes to in the admin area.

The problem I'm having is that every now and again, the variable drops out and I get sent back to the login page. VERY Frustrating, especially when I cannot seem to duplicate the error to find the problem!

1. Can anybody tell me why this is happening? I have read a bit about the different reasons, ie IE explorer's cookie management, the types of links etc, but nothing I do helps, and

2. is there a better way to restrict access to pages at the admin area other than session variables? preferrably something that is not so un-stable.

-------------------------------------------------------------
"The most overlooked advantage of owning a computer is that if they foul up there's no law against whacking them around a bit."
 
tsuji,

Thanks for that. That was one of the sites I went to and read about. However it did not resolve the issues. I have a feeling that it may be a server problem.

I learned how to place a cookie on the users hard drive for the session and look up that to allow access. Everything is as solid as a rock now.

While I understand that it may be less secure than a serve variable, a hacker will only be able to get this cookie if they know the access code in the first place which is stored in a database. When the user logs off the cookie is set to nothing as well as expiring after 1 day.

If the user have issues with this setup then it would probably be becasue they do have cookies enabled.

Thanks again

-------------------------------------------------------------
"The most overlooked advantage of owning a computer is that if they foul up there's no law against whacking them around a bit."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top