Solved

ASP: Session Variables & Cookies

Posted on 1998-05-11
1
193 Views
Last Modified: 2013-12-25
With Microsoft ASP, it is easy to create user-specific variables through the use of session variables. However, it would seem that the way IIS associates page requests with a particular browser is through the use of a cookie (ASPSESSIONID, I think it's called). This is fine and easy, but can session variables be used when a browser is set to refuse cookies? I don't see how this can be true. If so, what's the best way of detecting this condition and doing something about it? I've read the Microsoft Press book on ASP, but it skims over this area completely.
0
Comment
Question by:pob
1 Comment
 
LVL 28

Accepted Solution

by:
sybe earned 100 total points
ID: 1855951
If the user refuses the ASP-cookie, Session variables will not work.
You can ask for the cookie by Request.Servervariables("HTTP_COOKIE ")

There is not much you can do about it. You'll just have to think of doing it without sessionvariables, or warn the user that without accepting cookie, he won't get the full advantage of the site.

One way i can think of that is similar to Sessionvariables, is to       check in each page the users IP-number, put it in a storage (database), and add fields with the values of the sessionvariables you would have used. Of course this will cost a lot of performance. And you'll have to find a way to empty the database.




0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Problem to be resolved in this article Currently, development of website and web application can be done without writing thousands of lines of programming code by hand. Description This can be done through by using a open source framework such …
I've been asked to discuss some of the UX activities that I'm using with my team. Here I will share some details about how we approach UX projects.
The viewer will learn how to dynamically set the form action using jQuery.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now