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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session Variable problems

Status
Not open for further replies.

multiplex77

Programmer
Dec 25, 2001
302
SG
Hi,

I have an ASP driven site that uses Session variables to authenticate,

like: Login -> Set session variable -> Display page based on session variable.

The problem is, some browsers at my client's company can't view the entire page because it seems to not be accepting or storing Session variables. In the below example, I can never see Portion A on my client's browser because the Session("Access") is always disabled:

<% If InStr(1, Session(&quot;Access&quot;), &quot;multiplex&quot;) > 0 Then %>
Display portion A.
<% End If %>

I've tried replicating this problem scenario on my browser, but I can't. Now I know Session variables are tied to cookies, so I went, in Internet Explorer, to Tools-> Options -> Privacy -> Block all Cookies. But I can *still* log in successfully.

So is this a browser problem or an IIS problem or a coding problem?

Thanks for the help!
 
Make sure you close all instances of the browser, even launch Task Manager to see if IEXPLORE.EXE is still running. This will make sure that any changes to diabling/enabling cookies are set.

I have done the same test successfully on one browser, on one machine, with blocking on and off. Give that a try. _______________________________________________
OutsideIntranets.com
Stop wasting time, get to work
 
I have similar problems with IE 6.0 but not with other browsers.....I am wondering myself.....Please check yours.
 
This is totally to do with IE 6.0, do a search for ie6 session cookies problems and see how many problems other people are getting, I have it as well with all my sites.
The simple solution is tell them to goto Tools/Internet Options, click advanced and click override cookie handling.

All topics about this point to the above solution, real difficult but then thats MS

Saturday 12.00
im6.gif
im2.gif
im2.gif
20.00
im5.gif
im4.gif
im7.gif
3.00am
im8.gif
Sunday [img http
 
Thanks japes and Gary. I tried doing that but is still cannot repeat what happens to my client.

I set my Privacy Settings to &quot;Block ALL Cookies&quot;. Then I deleted all the cookies, closed my browser, ensured IEXPLORE.EXE is not running. But when I start up my application again, I can log in like as if cookies are still accepted.

I also tried going to Advanced, and Overriding automatic cookie handling. I &quot;Blocked all 1st and 3rd party cookies&quot; and cleared the checkbox for &quot;Always allow session cookies&quot;. But still everything is work as though cookies are accepted.

The only thing that replicates this problem is when the session times-out.

Is it something to do with IIS handling the Sessions at the server side?

Thanks for the help.
 
The session timeout can be changed from its default by using
<% session.timeout=60 %>
60 being the amount of minutes Saturday 12.00
im6.gif
im2.gif
im2.gif
20.00
im5.gif
im4.gif
im7.gif
3.00am
im8.gif
Sunday [img http
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top