Re: How to add 60 minutes to current time and have it properly
This WebDNA talk-list message is from 2005
It keeps the original formatting.
numero = 62865
interpreted = N
texte = That's kind of what I do this when setting 30-minute cookies, but make sure you allow for the time offset, in my case here in NJ it's 5 hours. Check to see if the projected expiration time falls between midnight and the cookie duration. Here's my code (showing the 5 hour offset):[setcookie name=[id]admin&value=allowed&path=/&expires=[format days_to_date %A, %d-%b-%Y][math]{[date]}[showif [math]{[time]}+{05:30:00}[/math]<[math]{00:30:00}[/math]]+{00/01/0000}[/showif][/math][/format] [math time]{[time]}+{05:30:00}[/math] GMT&domain=[getmimeheader host]]TerryAt 2:00 AM -0700 8/27/05, WebDNA Talk wrote:>From: Dale's Lists
>Subject: How to add 60 minutes to current time and have it properly> roll over to tomorrow>Date: Fri, 26 Aug 2005 21:39:47 -0500>>WebDNS 6.0a on Linux>--->>Hi,>>I am working on a session management process (using cookies) and am >getting stumped (probably something very simple) on adding 60 >minutes to the current time to extend the current session, yet >having it properly increment the date.>>Not sure if I should just check the seconds (using >[math]{[time]}[/math] ) value to see if it is between 0 and 3599 and >if it is, increment the date by 1, or if there is something built in >that I am missing.>>Thanks>>drt-- Terry Wilson | terry@terryfic.com | http://terryfic.comhttp://WhosComing.com - a simplified, affordable online reservation systemhttp://TightPods.com -- stylish protection for your laptop--------------------------------------------------------------------------Attitude is the only difference between ordeal and adventure.-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
|
- Re: How to add 60 minutes to current time and have it properly ( Terry Wilson 2005)
|
That's kind of what I do this when setting 30-minute cookies, but make sure you allow for the time offset, in my case here in NJ it's 5 hours. Check to see if the projected expiration time falls between midnight and the cookie duration. Here's my code (showing the 5 hour offset):[setcookie name=[id]admin&value=allowed&path=/&expires=[format days_to_date %A, %d-%b-%Y][math]{[date]}[showif [math]{[time]}+{05:30:00}[/math]<[math]{00:30:00}[/math]]+{00/01/0000}[/showif][/math][/format] [math time]{[time]}+{05:30:00}[/math] GMT&domain=[getmimeheader host]]TerryAt 2:00 AM -0700 8/27/05, WebDNA Talk wrote:>From: Dale's Lists >Subject: How to add 60 minutes to current time and have it properly> roll over to tomorrow>Date: Fri, 26 Aug 2005 21:39:47 -0500>>WebDNS 6.0a on Linux>--->>Hi,>>I am working on a session management process (using cookies) and am >getting stumped (probably something very simple) on adding 60 >minutes to the current time to extend the current session, yet >having it properly increment the date.>>Not sure if I should just check the seconds (using >[math]{[time]}[/math] ) value to see if it is between 0 and 3599 and >if it is, increment the date by 1, or if there is something built in >that I am missing.>>Thanks>>drt-- Terry Wilson | terry@terryfic.com | http://terryfic.comhttp://WhosComing.com - a simplified, affordable online reservation systemhttp://TightPods.com -- stylish protection for your laptop--------------------------------------------------------------------------Attitude is the only difference between ordeal and adventure.-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Terry Wilson
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
URL'ed value not written to DB URL'ed (2003)
PCS Frames (1997)
Quickie question on the email templates (1997)
Searching,Brain Dead! (1999)
question: back button prevention (1997)
Possible to reset Linux file permissions w/in webcat [shell] ? (2000)
[WebDNA] [announce] CICADA Gold Products (2009)
This is probably a stupid question... (2004)
FAX orders (1996)
Problem with updating 2.1b7 -> 2.1.1 (1998)
Multiple Passwords (1997)
WebCatalog Beta Documentation (1997)
Another reviewer 'forgets' NT WebCatalog (1998)
2.0 Info (1997)
http upload (2001)
Emailer (WebCat2) (1997)
Error .. (2003)
[WebDNA] mail rejection woes (2019)
Narrowing NT Crashing error (2000)
Re2: frames & carts (1997)