Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] help with asp/javascript date problem


  • From: javascript@xxxxxxxxxx (Meyer, Jeanine)
  • Subject: [Javascript] help with asp/javascript date problem
  • Date: Thu, 31 Oct 2002 14:20:20 -0500

hello,
I have found you all in various forums.
I am having a problem with setting the expiration for cookies using asp and
JavaSCript.  I think it is a datatype conversion issue.
Here is the code:
       var dtNow=new Date(); //get now
        var dtLater=new Date(dtNow.getTime()+5 * 60000); // add your 5
minutes
        var later=dtLater.toLocaleString(); //convert to Local time
        Response.Cookies("currentclientname") = sname;
  	Response.Cookies("currentclientname").expires = later;

Any suggestions will be appreciated.
thanks,
Jeanine