The cookie is crumbling...

T

Tim Johnson

Hi,

I am starting to use cookies in my ASP pages, this is
new for me, I am using the following code to create a
cookie:

Response.Cookies("bookedby")= Request.Form("txtBookedBy")
Response.Cookies("bookedby").expires="#July 29, 2003#"

However, when the page is opened I get the following
error:

Error Type:
Microsoft VBScript runtime (0x800A000D)
Type mismatch: 'Response.Cookies(...).Expires'
/MRBS/addbookingtodb.asp, line 5

Line 5 is when I try to set the expiry. Please help :)

TIA.
 
R

Ray at

Take the date out of quotes so you just have:

Response.Cookies("bookedby").Expires=#July 29, 2003#

Ray at home
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top