Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Aug 12th, 2012  |  syntax: None  |  size: 0.22 KB  |  hits: 11  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Validate Session with Http Module
  2. if (Session["LoggedInUser"] != null)
  3.  {
  4.      user = (User)Session["LoggedInUser"];
  5.  }
  6.  else
  7.  {
  8.      FormsAuthentication.SignOut();
  9.      FormsAuthentication.RedirectToLoginPage();
  10.  }