Search code examples
asp.net-mvc-3sessionextend

Do not prolong session expiration when ajax call makes


I use slidingExpiration session on my web site. And I also added ajax call to check each 15 min session expiration to redirect user on login page. Is it possible to not extend session when this ajax is called?


Solution

  • Answer found. To avoid session expiration extend, mark controller by [SessionState(SessionStateBehavior.Disabled)] attribute