EnjoySharePoint YouTube Channel

Cookieless session in Asp.Net

In this post, we will discuss what is a cookieless session in Asp.Net. Also, you can check out my previous posts on Hiding methods in C#.NetAsp.Net MVC4 sample application and Simple JavaScript textbox validation example in Asp.Net.
– When the browser is disabled with cookies then the session for the client will not be maintained. Because session id will be sent to the client browser in form of an inmemmory cookie.
– The problem has been overcome in Asp.Net by supporting cookieless session.
– When the session id is appended to the URL in the form of Query string then it is called cookieless session.
– To use cookieless session we have to modify in the web.config file like below:
<SessionState ——-
Cookieless=”ture/false” timeout=”20″ />
The URL looks like below:
last is the session id which is appended as querystring parameter.
– When the client makes changes with the URL the session will be lost. This makes a new session to be created for the client.
How to know if browser supports cookie or not:
If it returns true means browser supports cookie and if it returns false then browser does not support cookie.
Check out Best Alternative to InfoPath -> Try Now
You May Also like the Following SharePoint Tutorials:

About Bijay Kumar

I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SharePointSky.com

View all posts by Bijay Kumar →