Session State

As I mentioned at the beginning of this chapter, there were several ways to handle the state information of a user’s visit or session on your web site. All the methods had an inherent problem in one factor or another. Let’s look at a few of the problems that some of the solutions used in the past have faced.

Session Object

  • Lost data if web services were stopped and restarted

  • Not very scalable; server resources required

  • Won’t work in a web farm

  • Won’t work with user’s cookies disabled

Cookies

  • Won’t work with user’s cookies disabled

  • Hidden text boxes

  • Information is exposed to anyone that knows how to view source

  • Can be tampered with if a malicious visitor wants to

  • Work only if a user submits a form

QueryString

  • Exposed in the browser’s ...

Get ASP.NET for Web Designers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.