- Cookies is a small text file sent by web server and saved by web browser on client machine.
- Common use of cookies is to remember last logged in time of a visitor.
- Usually cookies are not used to store sensitive information's like passwords without prior encryption as they are just a plain text.
- Cookie size is limited to 4096 bytes. So cookies are used to store small amounts of data, often just user id.
- Also, number of cookies is limited to 20 per website. If you make new cookie when you already have 20 cookies, browser will delete oldest one.
To check if a browser accepts cookies, use below code in C# :
if (Request.Browser.Cookies)
{
// Cookies supported
}
else
{
// Web browser not supports cookies
}
Ref : here
{
// Cookies supported
}
else
{
// Web browser not supports cookies
}
Ref : here
0 comments:
Post a Comment