Guest User

Untitled

a guest
May 20th, 2018
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. public static string SessionKey
  2. {
  3. get { return GetFacebookCookie("session_key"); }
  4. }
  5.  
  6. private static string GetFacebookCookie(string propertyName)
  7. {
  8. var fullName = ApiKey + "_" + propertyName;
  9.  
  10. if (HttpContext.Current == null || HttpContext.Current.Request.Cookies[fullName] == null)
  11. return null;
  12.  
  13. return HttpContext.Current.Request != null ? HttpContext.Current.Request.Cookies[fullName].Value : null;
  14. }
Add Comment
Please, Sign In to add comment