Quote:
quote:well i am not sure i am asking if i will store username only in cookie but in web site user have to provide password also with that username so i am thinking that if i store username only in cookie an dif any person read it then he may not be able to use web site as he donot have password. am i right?
|
Yes, true. ALthough IMO it's still a security risk. Up to you though....
Quote:
quote:yes i am sure sessions are not working. you said right.
|
I don't believe that. Try this:
1. Create an ASPX page with this markup:
Code:
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
<a href="http://www.google.com/">Go to Google</a>
2. In Code Behind add this:
Code:
Session["Test"] = "Something";
Label1.Text = Session.SessionID;
(Notice it's important to assign something to Session state first.
3. Run the page. Note the Session ID
4. Click the link to go to Google
5. Click the back button
6. Press Ctrl+F5 to refresh the page a couple of times.
The ID will be the same as in step 3.
Quote:
quote:link refer to a help page from where i can get code how to store values in cookies and read them.
|
The best link is
www.google.com Searching for Cookies ASP.NET should give you plenty results to work with.
Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of
ASP.NET 2.0 Instant Results and
Beginning Dreamweaver MX / MX 2004