Beispiel #1
0
        public IActionResult Index()
        {
            CookieMgrService.Set("user_is_admin", "true", 1, true);

            ViewData["user_is_admin"] = true;

            return(View());
        }
Beispiel #2
0
 protected void SetCookieValue(string key, string value, int?expireTime, bool isEssential)
 {
     CookieMgrService.Set(key, value, expireTime, isEssential);
 }
Beispiel #3
0
 protected void SetCookieValue(SessionValues key, string value, int?expireTime, bool isEssential)
 {
     CookieMgrService.Set(key.ToString(), value, expireTime, isEssential);
 }