Wrox Home  
Search P2P Archive for: Go

  Return to Index  

aspx_beginners thread: cookies


Message #1 by Elissa Setarehshenas <elissasetareh@y...> on Thu, 9 Aug 2001 11:07:44 -0700 (PDT)
Hi

Can anybody help me with this problem.  I am working

on a aspx application. On one page cookies are being

set using javascript. On another page I allow the user

to select another item this will cause the cookies to

be updated with new values and they update and display

properly on the current page.   On the next page  the

new values should be displayed but the old values are

still retained in the cookies. I tried setting an

experation date for the cookie as someone suggested

but it doesn't make a difference.  Here's the code

that I'm using.



HttpCookie bldg = null;

bldg = Request.Cookies["bldg"];

bldg.Value = e.Item.Cells[0].Text;

Response.Cookies["bldg"].Expires 

DateTime.Now.AddDays(30.0);



This code changes what's inside the cookie for the 

current page but not the pages that follow it. Any

ideas on what I should try next? 



Thanks for your help,

Elissa Setareh   


  Return to Index