Finding cookies in C

Discussion in 'C' started by techinspiration, Apr 15, 2010.

  1. techinspiration

    techinspiration New Member

    Joined:
    Feb 14, 2010
    Messages:
    54
    Likes Received:
    0
    Trophy Points:
    0
    if (Request.Cookies["fakecookiename"] != null)
    {
    Response.Redirect("default.aspx");
    }

    Where "fakecookiename" is replaced with a unique name for you cookie that you made with the previous code.

    and the response.redirect of the action if the value is not null. You can do pretty much anything in the statement, it doesnt just have to be a page redirect.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice