Re: 2cd pair.. [math] and European Date format
This WebDNA talk-list message is from 2004
It keeps the original formatting.
numero = 59090
interpreted = N
texte = Well, nevermind... I just wasnt understanding how the internal formatting worked..If I force the euro date format then I get the desired results.. ie:[text]timestamp=[math]((([math]{[date %d/%m/%Y]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text]Date: [format days_to_date %d/%m/%Y][format .6d][math]([timestamp]/86400)+1[/math][/format][/format]works..I think the [date %d/%m/%Y] forces the "/" which seems to be the difference..DonovanDonovan Brooke wrote:> Hello,> I've used a bit of code supplied by Tom Duke without problems for> quite some time... However, I recently used it on a clients machine who> happens to be in Europe and using the dd/mm/yyyy format for dates.> This "timestamp" is a date and time stamp down to seconds...> > > I'm getting a strange results..> > Here is the code that works for US:> [text]timestamp=[math]((([math]{[date]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text] > > > conversion back:> Date: [format days_to_date][format > .6d][math]([timestamp]/86400)+1[/math][/format][/format]> > The above produces a good date of, this case, 08/18/2004 (today)> > > > > Here is the code that I'm trying to use for the different (euro) date > format:> [text]timestamp=[math]((([math]{[date > %m/%d/%Y]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text]> > Date: [format days_to_date %m/%d/%Y][format > .6d][math]([timestamp]/86400)+1[/math][/format][/format]> > This produces a result of 05/09/2004> > > > Can anyone see why this converts back to may 9th?> > Thx,> Donovan-- =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o DONOVAN D. BROOKE Eucalyptus Design <-Web Development (specializing in eCommerce), -> <-Graphic Design, and Pre-Press Consultation -> ADDRESS:> Donovan Brooke DBA Eucalyptus Design N2862 Summerville Park Rd. Lodi, WI 53555 PH:> 1.608.592.3567 Web:> http://www.euca.us =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o-------------------------------------------------------------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:
Well, nevermind... I just wasnt understanding how the internal formatting worked..If I force the euro date format then I get the desired results.. ie:[text]timestamp=[math]((([math]{[date %d/%m/%Y]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text]Date: [format days_to_date %d/%m/%Y][format .6d][math]([timestamp]/86400)+1[/math][/format][/format]works..I think the [date %d/%m/%Y] forces the "/" which seems to be the difference..DonovanDonovan Brooke wrote:> Hello,> I've used a bit of code supplied by Tom Duke without problems for> quite some time... However, I recently used it on a clients machine who> happens to be in Europe and using the dd/mm/yyyy format for dates.> This "timestamp" is a date and time stamp down to seconds...> > > I'm getting a strange results..> > Here is the code that works for US:> [text]timestamp=[math]((([math]{[date]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text] > > > conversion back:> Date: [format days_to_date][format > .6d][math]([timestamp]/86400)+1[/math][/format][/format]> > The above produces a good date of, this case, 08/18/2004 (today)> > > > > Here is the code that I'm trying to use for the different (euro) date > format:> [text]timestamp=[math]((([math]{[date > %m/%d/%Y]}[/math])-1)*86400)+([math]{[time]}[/math])[/math][/text]> > Date: [format days_to_date %m/%d/%Y][format > .6d][math]([timestamp]/86400)+1[/math][/format][/format]> > This produces a result of 05/09/2004> > > > Can anyone see why this converts back to may 9th?> > Thx,> Donovan-- =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o DONOVAN D. BROOKE Eucalyptus Design <-Web Development (specializing in eCommerce), -> <-Graphic Design, and Pre-Press Consultation -> ADDRESS:> Donovan Brooke DBA Eucalyptus Design N2862 Summerville Park Rd. Lodi, WI 53555 PH:> 1.608.592.3567 Web:> http://www.euca.us =o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o=o-------------------------------------------------------------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/
Donovan Brooke
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:
If search results are blank... (2003)
RE: OK, here goes... (1997)
Summary layout (1997)
MOOOOOO (2000)
Generating Report Totals (1997)
Security Issues and WebCommerce Solution (1997)
Tip: upgrading to WebCatalog 3.x, fields to watch for (1999)
zzounds.com. Was: ANN: Strategic Partnership with BuyStream Announced. (2000)
Using WC for Bulk Emailings (1997)
Speed questions (1998)
Questions To Answer (1997)
[WebDNA] [ipaddress] - [RealIP] - Not working properly (2016)
Bug? (1997)
WebCat2b13MacPlugIn - [shownext method=post] ??? (1997)
Web Developer Product Awards (1997)
Help :( (2001)
sorting by date Y2K mix up (2000)
[showif] and equality (1998)
SMSI: Forged email addresses on the talk list ... (2002)
[shownext max=?] armed (1997)