In this article I will show you how you can increate session
timeout in an mvc4 application. It will help you on increasing the timeout
value of the session. In this case the stored information in session will
retain for longer time.
Some of my previous articles are as follows:
Simple
Login From in Asp.Net MVC Using C#.Net, Bind
and Retrieve ListBox Selected Value in MVC Using C#.Net, Bind
DropDownList Using Entity Framework in ASP.Net MVC Using C#, Error
: SQL Server Compact is not intended for ASP.NET development..
So for increasing the session value we needed to add a small
configuration in our asp.net mvc web.config file.
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on
how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=152368
-->
<configuration>
<system.web>
<sessionState mode="InProc" timeout="30" />
</system.web>
</configuration>
|
In above configuration we have raised the session time
out up to 30 minutes.
0 comments:
Please let me know your view