RE: [WebDNA] Dead line Time Math

This WebDNA talk-list message is from

2017


It keeps the original formatting.
numero = 113515
interpreted = N
texte = 1110 This is a multi-part message in MIME format. ------=_NextPart_000_01A7_01D2A7A6.E2E872E0 Content-Type: multipart/alternative; boundary="----=_NextPart_001_01A8_01D2A7A6.E2E872E0" ------=_NextPart_001_01A8_01D2A7A6.E2E872E0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Oops sorry .one too many maths [ . ] when trying to adapt the example for you .should be like this .. [!] [/!][text show=F]todaydate=[math]{[date]}[/math][/text][!] [/!][text show=F]todaytime=[math]{[time]}[/math][/text][!] [/!][text show=F]expiredate=[math]{03/30/2017}[/math][/text][!] [/!][text show=F]expiretime=[math]{17:00:00}[/math][/text][!] [/!][if [math]([expiredate]*86400)+[expiretime][/math]>[math]([todaydate]*86400)+[to daytime][/math]][then][!] [/!]Here's the registration form ...[!] [/!][/then][else][!] [/!]Sorry, registration closed[!] [/!][/else][/if][!] [/!] Cheers TDn From: Terry Nair [mailto:terrynair@prism4u.com] Sent: Tuesday, March 28, 2017 09:27 To: talk@webdna.us Subject: RE: [WebDNA] Dead line Time Math Or something like this ... [!] [/!][text show=F]todaydate=[math]{[date]}[/math][/text][!] [/!][text show=F]todaytime=[math]{[time]}[/math][/text][!] [/!][text show=F]expiredate=[math]{03/30/2017}[/math][/text][!] [/!][text show=F]expiretime=[math]{17:00:00}[/math][/text][!] [/!][if [math]([math]{[expiredate]}[/math]*86400)+[math]{[expiretime]}[/math][/math] >[math]([todaydate]*86400)+[todaytime][/math]][then][!] [/!]Here's the registration form ...[!] [/!][/then][else][!] [/!]Sorry, registration closed[!] [/!][/else][/if][!] [/!] Cheers TDn From: Stuart Tremain [mailto:webdna@idfk.com.au] Sent: Tuesday, March 28, 2017 06:40 To: WebDNA Talk List Subject: Re: [WebDNA] Dead line Time Math A real life example using real dates and time will help you to see what is happening, note that BOTH comparisons must be true to get a THEN result because we are using & in the IF. CLOSINGDATE=03/30/2017 CLOSINGTIME=17:00:00 So closing time is 5pm on 30th March 2017 We are doing: IF (part a & part b) OR (part c & part d) because we also need to calculate for the DAY of closing. [IF ((03/28/2017>03/30/2017)&(09:00:00>17:00:00))|((03/28/2017=03/30/2017)&(09:0 0:00>17:00:00))] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] <<< This is the result [/IF] [IF ((03/30/2017>03/30/2017)&(09:00:00>17:00:00))|((03/30/2017=03/30/2017)&(09:0 0:00>17:00:00))] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] <<< This is the result [/IF] [IF ((03/30/2017>03/30/2017)&(17:00:01>17:00:00))|((03/30/2017=03/30/2017)&(17:0 0:01>17:00:00))] [THEN]Sorry, registration closed.[/THEN] <<< This is the result because the second part of IF is true [ELSE]Here's the registration form ...[/ELSE] [/IF] Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 09:34, Stuart Tremain wrote: Sorry, I did not take into account that we also need a date = Give me a few minutes. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 09:23, Lawrence Banahan wrote: This only works if {[TIMENOW}>{[CLOSINGTIME} if you connect in the morning timenow is 9am and closing time 12am this comparaison doesn't work. It works only in the morning. Am I right? 2017-03-28 0:05 GMT+02:00 Stuart Tremain : [IF ([MATH]{[TODAYSDATE}[/MATH]>[MATH]{[CLOSINGDATEDATE}[/MATH])&([MATH]{[TIMENO W}[/MATH]>[MATH]{[CLOSINGTIME}[/MATH])] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] [/IF] Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 08:38, Lawrence Banahan wrote: I was adding seconds to days. This can't work. Is there a way to get this work? [if [math]{[todaysdate]}+{[TodaysTIME]}[/math]>[math]{03/26/2017}+{12:00:00}[/ma th]] [then]Sorry, registration closed.
[/then] [else]Here's the registration form ...
[/else] [/if] Kenneth Grome 27 mars 2017 22:37 I think this is what you want: [if [math]{[date]}[/math]>[math]{03/26/2017}[/math]] [then]Sorry, registration closed.[/then] [else]Here's the registration form ...[/else] [/if] Regards, Kenneth Grome WebDNA Solutions http://www.webdnasolutions.com Web Database Systems and Linux Server Administration --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_001_01A8_01D2A7A6.E2E872E0 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

= Oops sorry …one too many maths [ … ] when trying to adapt = the example for you …should be like this = ….

=  

= [!]

= [/!][text = show=3DF]todaydate=3D[math]{[date]}[/math][/text][!]

= [/!][text = show=3DF]todaytime=3D[math]{[time]}[/math][/text][!]

= [/!][text = show=3DF]expiredate=3D[math]{03/30/2017}[/math][/text][!]

= [/!][text = show=3DF]expiretime=3D[math]{17:00:00}[/math][/text][!]=

= [/!][if = [math]([expiredate]*86400)+[expiretime][/math]>[math]([todaydate]*8640= 0)+[todaytime][/math]][then][!]

= [/!]Here's the registration form ...[!]

= [/!][/then][else][!]

= [/!]Sorry, registration closed[!]

= [/!][/else][/if][!]

= [/!]

=  

= Cheers TDn

=  

=  

=  

From:= = Terry Nair [mailto:terrynair@prism4u.com]
Sent: Tuesday, = March 28, 2017 09:27
To: talk@webdna.us
Subject: RE: = [WebDNA] Dead line Time Math

 

= Or something like this …..

=  

= [!]

= [/!][text = show=3DF]todaydate=3D[math]{[date]}[/math][/text][!]

= [/!][text = show=3DF]todaytime=3D[math]{[time]}[/math][/text][!]

= [/!][text = show=3DF]expiredate=3D[math]{03/30/2017}[/math][/text][!]

= [/!][text = show=3DF]expiretime=3D[math]{17:00:00}[/math][/text][!]=

= [/!][if = [math]([math]{[expiredate]}[/math]*86400)+[math]{[expiretime]}[/math][/ma= th]>[math]([todaydate]*86400)+[todaytime][/math]][then][!]<= /span>

= [/!]Here's the registration form ...[!]

= [/!][/then][else][!]

= [/!]Sorry, registration closed[!]

= [/!][/else][/if][!]

= [/!]

=  

= Cheers TDn

=  

From:= = Stuart Tremain [mailto:webdna@idfk.com.au] =
Sent: Tuesday, March 28, 2017 06:40
To: WebDNA Talk = List
Subject: Re: [WebDNA] Dead line Time = Math

 

A real = life example using real dates and time will help you to see what is = happening, note that BOTH comparisons must be true to get a THEN result = because we are using & in the IF.

 

CLOSINGDATE=3D03/30/2017

CLOSINGTIME=3D17:00:00

 

So closing time is 5pm on 30th March = 2017

 

 

We are doing: IF (part a & part b) OR (part c = & part d) because  we also need to calculate for the DAY of = closing.

 

[IF = ((03/28/2017>03/30/2017)&(09:00:00>17:00:00))|((03/28/2017=3D03= /30/2017)&(09:00:00>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration = closed.[/THEN]

        &n= bsp;   [ELSE]Here's the registration form ...[/ELSE] = <<< This is the result

[/IF]

 

 

[IF = ((03/30/2017>03/30/2017)&(09:00:00>17:00:00))|((03/30/2017=3D03= /30/2017)&(09:00:00>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration = closed.[/THEN]

        &n= bsp;   [ELSE]Here's the registration form ...[/ELSE] = <<< This is the result

[/IF]

 

 

[IF = ((03/30/2017>03/30/2017)&(17:00:01>17:00:00))|((03/30/2017=3D03= /30/2017)&(17:00:01>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration closed.[/THEN] =  <<< This is the result because the second part of IF is = true

        &n= bsp;   [ELSE]Here's the registration form = ....[/ELSE] 

[/IF]

 

 

 

 

 

Kind = regards

 

Stuart = Tremain

Pharoah Lane = Software

AUSTRALIA

 

 

 

 

 

On 28 Mar 2017, at 09:34, Stuart Tremain <webdna@idfk.com.au> = wrote:

 

Sorry, I did not take into account that we also need a = date =3D

 

Give me a few minutes.

 

 

Kind = regards

 = ;

Stuart = Tremain

Pharoah = Lane Software

AUSTRALIA<= o:p>

 = ;

 = ;

 

 

 

On 28 Mar 2017, at 09:23, Lawrence Banahan <banahan.l@gmail.com> = wrote:

 

This only works if {[TIMENOW}>{[CLOSINGTIME}
if you connect = in the morning timenow is 9am and closing time 12am this comparaison = doesn't work. It works only in the morning.

Am I = right?

 

2017-03-28 0:05 GMT+02:00 Stuart Tremain <webdna@idfk.com.au>:

[IF = ([MATH]{[TODAYSDATE}[/MATH]>[MATH]{[CLOSINGDATEDATE}[/MATH])&([MAT= H]{[TIMENOW}[/MATH]>[MATH]{[CLOSINGTIME}[/MATH])]

=

[THEN]Sorry, registration = closed.[/THEN]

[ELSE]Here's the registration form = ....[/ELSE]

[/IF]

 

 

 

 

Kind regards

 

Stuart Tremain

Pharoah Lane Software

AUSTRALIA

 

 

 

 

 

On 28 Mar 2017, at 08:38, Lawrence Banahan <banahan.l@gmail.com> = wrote:

 

I was adding seconds = to days.
This can't work.
Is there a way to get this = work?

[if = [math]{[todaysdate]}+{[TodaysTIME]}[/math]>[math]{03/26/2017}+{12:00:0= 0}[/math]]
[then]Sorry, registration = closed.<br>[/then]
[else]Here's the registration form = ....<br>[/else]
[/if]

27 mars = 2017 22:37

I think = this is what you want:

[if = [math]{[date]}[/math]>[math]{03/26/2017}[/math]]
[then]Sorry, = registration closed.[/then]
[else]Here's the registration form = ....[/else]
[/if]

Regards,
Kenneth Grome
WebDNA = Solutions
http://www.webdnasolutions.com
Web Database = Systems and Linux Server = Administration

-------------------------------------------------= --------
This message is sent to you because you are subscribed = to
the mailing list <talk@webdna.us>.
To unsubscribe, E-mail = to: <talk-leave@webdna.us>
archives: http://mail.webdna.us/list/talk@webdna.us
Bug = Reporting: support@webdna.us

=

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug = Reporting: support@webdna.us

=

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug = Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_001_01A8_01D2A7A6.E2E872E0-- ------=_NextPart_000_01A7_01D2A7A6.E2E872E0 Content-Type: image/jpeg; name="image001.jpg" Content-Transfer-Encoding: base64 Content-ID: /9j/4AAQSkZJRgABAQEARwBHAAD/2wBDAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQECAQEB AQEBAgICAgICAgICAgICAgICAgICAgICAgICAgICAgL/2wBDAQEBAQEBAQICAgICAgICAgICAgIC AgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgL/wAARCAAZABkDAREA AhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAABgcICQr/xAA0EAABAwMCAgUKBwAAAAAAAAACAQME BQYRABITIQcUMUF2CBUXIjI2N0JRtVRWkZOV0dL/xAAYAQEAAwEAAAAAAAAAAAAAAAADAAEEAv/E ACQRAAICAAQGAwAAAAAAAAAAAAABAhEDMrHREyExM0FxgfDx/9oADAMBAAIRAxEAPwDuEt+gW/UL et6oVC3rfqNQqFv0OfPn1GhUqfOmzZtKZlS5UqZMaNwzNwiJVIl7eXLCaZIGwBl3TY8epPx2+jy2 ZNPjvkwc9uhW8j7nCPhvOsQliYIeS7cvCpp8o50qwrC4v3lsNSDbdmTEhvs2tahxpfV3WnmbbozJ Ew/gwdadbYExVRXKEKoSdvJcaOSqxE7/AAiX0gXx+a69/JSf9alIlste0VzaNpeFrcT9KKymotyi aZ0KRCnzacoE7Kjzn4gi2KqUh3jqDHDHv4mRUfruTWlMzlVUKIVNp9GguEJnAh0+IZjyAiisgyRD nu5azS8miKqjOTVkKqS/psG37fo1Fbabeg25b8eZPeFJBBJSjMG5HjMeyihnaauZwe4OGiju13GA cpOwBeN+U8/IkGbsiS8b7ryogmbzhbyc9REROfZhERO5ETShjPtvpGqTUyLErytS4siSwx5x2tRH 4hPOI0DkjZtaJtFxuVEbIUUiyeNujlBUJGbJN6nM/Cyf2Hf60YgjvKA+NPSP4gT7axpcPtr51YWJ nYn9dnAQWl722p4ot37yzqnlfp6FrqbwawG8/9k= ------=_NextPart_000_01A7_01D2A7A6.E2E872E0-- . Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  2. Re: [WebDNA] Dead line Time Math (Tom Duke 2017)
  3. Re: [WebDNA] Dead line Time Math (Michael Davis 2017)
  4. RE: [WebDNA] Dead line Time Math ("Terry Nair" 2017)
  5. RE: [WebDNA] Dead line Time Math ("Terry Nair" 2017)
  6. Re: [WebDNA] Dead line Time Math (Stuart Tremain 2017)
  7. Re: [WebDNA] Dead line Time Math (Stuart Tremain 2017)
  8. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  9. Re: [WebDNA] Dead line Time Math (Stuart Tremain 2017)
  10. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  11. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  12. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  13. Re: [WebDNA] Dead line Time Math (Lawrence Banahan 2017)
  14. Re: [WebDNA] Dead line Time Math (Kenneth Grome 2017)
1110 This is a multi-part message in MIME format. ------=_NextPart_000_01A7_01D2A7A6.E2E872E0 Content-Type: multipart/alternative; boundary="----=_NextPart_001_01A8_01D2A7A6.E2E872E0" ------=_NextPart_001_01A8_01D2A7A6.E2E872E0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Oops sorry .one too many maths [ . ] when trying to adapt the example for you .should be like this .. [!] [/!][text show=F]todaydate=[math]{[date]}[/math][/text][!] [/!][text show=F]todaytime=[math]{[time]}[/math][/text][!] [/!][text show=F]expiredate=[math]{03/30/2017}[/math][/text][!] [/!][text show=F]expiretime=[math]{17:00:00}[/math][/text][!] [/!][if [math]([expiredate]*86400)+[expiretime][/math]>[math]([todaydate]*86400)+[to daytime][/math]][then][!] [/!]Here's the registration form ...[!] [/!][/then][else][!] [/!]Sorry, registration closed[!] [/!][/else][/if][!] [/!] Cheers TDn From: Terry Nair [mailto:terrynair@prism4u.com] Sent: Tuesday, March 28, 2017 09:27 To: talk@webdna.us Subject: RE: [WebDNA] Dead line Time Math Or something like this ... [!] [/!][text show=F]todaydate=[math]{[date]}[/math][/text][!] [/!][text show=F]todaytime=[math]{[time]}[/math][/text][!] [/!][text show=F]expiredate=[math]{03/30/2017}[/math][/text][!] [/!][text show=F]expiretime=[math]{17:00:00}[/math][/text][!] [/!][if [math]([math]{[expiredate]}[/math]*86400)+[math]{[expiretime]}[/math][/math] >[math]([todaydate]*86400)+[todaytime][/math]][then][!] [/!]Here's the registration form ...[!] [/!][/then][else][!] [/!]Sorry, registration closed[!] [/!][/else][/if][!] [/!] Cheers TDn From: Stuart Tremain [mailto:webdna@idfk.com.au] Sent: Tuesday, March 28, 2017 06:40 To: WebDNA Talk List Subject: Re: [WebDNA] Dead line Time Math A real life example using real dates and time will help you to see what is happening, note that BOTH comparisons must be true to get a THEN result because we are using & in the IF. CLOSINGDATE=03/30/2017 CLOSINGTIME=17:00:00 So closing time is 5pm on 30th March 2017 We are doing: IF (part a & part b) OR (part c & part d) because we also need to calculate for the DAY of closing. [IF ((03/28/2017>03/30/2017)&(09:00:00>17:00:00))|((03/28/2017=03/30/2017)&(09:0 0:00>17:00:00))] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] <<< This is the result [/IF] [IF ((03/30/2017>03/30/2017)&(09:00:00>17:00:00))|((03/30/2017=03/30/2017)&(09:0 0:00>17:00:00))] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] <<< This is the result [/IF] [IF ((03/30/2017>03/30/2017)&(17:00:01>17:00:00))|((03/30/2017=03/30/2017)&(17:0 0:01>17:00:00))] [THEN]Sorry, registration closed.[/THEN] <<< This is the result because the second part of IF is true [ELSE]Here's the registration form ...[/ELSE] [/IF] Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 09:34, Stuart Tremain wrote: Sorry, I did not take into account that we also need a date = Give me a few minutes. Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 09:23, Lawrence Banahan wrote: This only works if {[TIMENOW}>{[CLOSINGTIME} if you connect in the morning timenow is 9am and closing time 12am this comparaison doesn't work. It works only in the morning. Am I right? 2017-03-28 0:05 GMT+02:00 Stuart Tremain : [IF ([math]{[TODAYSDATE}[/MATH]>[math]{[CLOSINGDATEDATE}[/MATH])&([math]{[TIMENO W}[/MATH]>[math]{[CLOSINGTIME}[/MATH])] [THEN]Sorry, registration closed.[/THEN] [ELSE]Here's the registration form ...[/ELSE] [/IF] Kind regards Stuart Tremain Pharoah Lane Software AUSTRALIA webdna@idfk.com.au On 28 Mar 2017, at 08:38, Lawrence Banahan wrote: I was adding seconds to days. This can't work. Is there a way to get this work? [if [math]{[todaysdate]}+{[TodaysTIME]}[/math]>[math]{03/26/2017}+{12:00:00}[/ma th]] [then]Sorry, registration closed.
[/then] [else]Here's the registration form ...
[/else] [/if] Kenneth Grome 27 mars 2017 22:37 I think this is what you want: [if [math]{[date]}[/math]>[math]{03/26/2017}[/math]] [then]Sorry, registration closed.[/then] [else]Here's the registration form ...[/else] [/if] Regards, Kenneth Grome WebDNA Solutions http://www.webdnasolutions.com Web Database Systems and Linux Server Administration --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us --------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_001_01A8_01D2A7A6.E2E872E0 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

= Oops sorry …one too many maths [ … ] when trying to adapt = the example for you …should be like this = ….

=  

= [!]

= [/!][text = show=3DF]todaydate=3D[math]{[date]}[/math][/text][!]

= [/!][text = show=3DF]todaytime=3D[math]{[time]}[/math][/text][!]

= [/!][text = show=3DF]expiredate=3D[math]{03/30/2017}[/math][/text][!]

= [/!][text = show=3DF]expiretime=3D[math]{17:00:00}[/math][/text][!]=

= [/!][if = [math]([expiredate]*86400)+[expiretime][/math]>[math]([todaydate]*8640= 0)+[todaytime][/math]][then][!]

= [/!]Here's the registration form ...[!]

= [/!][/then][else][!]

= [/!]Sorry, registration closed[!]

= [/!][/else][/if][!]

= [/!]

=  

= Cheers TDn

=  

=  

=  

From:= = Terry Nair [mailto:terrynair@prism4u.com]
Sent: Tuesday, = March 28, 2017 09:27
To: talk@webdna.us
Subject: RE: = [WebDNA] Dead line Time Math

 

= Or something like this …..

=  

= [!]

= [/!][text = show=3DF]todaydate=3D[math]{[date]}[/math][/text][!]

= [/!][text = show=3DF]todaytime=3D[math]{[time]}[/math][/text][!]

= [/!][text = show=3DF]expiredate=3D[math]{03/30/2017}[/math][/text][!]

= [/!][text = show=3DF]expiretime=3D[math]{17:00:00}[/math][/text][!]=

= [/!][if = [math]([math]{[expiredate]}[/math]*86400)+[math]{[expiretime]}[/math][/ma= th]>[math]([todaydate]*86400)+[todaytime][/math]][then][!]<= /span>

= [/!]Here's the registration form ...[!]

= [/!][/then][else][!]

= [/!]Sorry, registration closed[!]

= [/!][/else][/if][!]

= [/!]

=  

= Cheers TDn

=  

From:= = Stuart Tremain [mailto:webdna@idfk.com.au] =
Sent: Tuesday, March 28, 2017 06:40
To: WebDNA Talk = List
Subject: Re: [WebDNA] Dead line Time = Math

 

A real = life example using real dates and time will help you to see what is = happening, note that BOTH comparisons must be true to get a THEN result = because we are using & in the IF.

 

CLOSINGDATE=3D03/30/2017

CLOSINGTIME=3D17:00:00

 

So closing time is 5pm on 30th March = 2017

 

 

We are doing: IF (part a & part b) OR (part c = & part d) because  we also need to calculate for the DAY of = closing.

 

[IF = ((03/28/2017>03/30/2017)&(09:00:00>17:00:00))|((03/28/2017=3D03= /30/2017)&(09:00:00>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration = closed.[/THEN]

        &n= bsp;   [ELSE]Here's the registration form ...[/ELSE] = <<< This is the result

[/IF]

 

 

[IF = ((03/30/2017>03/30/2017)&(09:00:00>17:00:00))|((03/30/2017=3D03= /30/2017)&(09:00:00>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration = closed.[/THEN]

        &n= bsp;   [ELSE]Here's the registration form ...[/ELSE] = <<< This is the result

[/IF]

 

 

[IF = ((03/30/2017>03/30/2017)&(17:00:01>17:00:00))|((03/30/2017=3D03= /30/2017)&(17:00:01>17:00:00))]

        &n= bsp;   [THEN]Sorry, registration closed.[/THEN] =  <<< This is the result because the second part of IF is = true

        &n= bsp;   [ELSE]Here's the registration form = ....[/ELSE] 

[/IF]

 

 

 

 

 

Kind = regards

 

Stuart = Tremain

Pharoah Lane = Software

AUSTRALIA

 

 

 

 

 

On 28 Mar 2017, at 09:34, Stuart Tremain <webdna@idfk.com.au> = wrote:

 

Sorry, I did not take into account that we also need a = date =3D

 

Give me a few minutes.

 

 

Kind = regards

 = ;

Stuart = Tremain

Pharoah = Lane Software

AUSTRALIA<= o:p>

 = ;

 = ;

 

 

 

On 28 Mar 2017, at 09:23, Lawrence Banahan <banahan.l@gmail.com> = wrote:

 

This only works if {[TIMENOW}>{[CLOSINGTIME}
if you connect = in the morning timenow is 9am and closing time 12am this comparaison = doesn't work. It works only in the morning.

Am I = right?

 

2017-03-28 0:05 GMT+02:00 Stuart Tremain <webdna@idfk.com.au>:

[IF = ([math]{[TODAYSDATE}[/MATH]>[math]{[CLOSINGDATEDATE}[/MATH])&([MAT= H]{[TIMENOW}[/MATH]>[math]{[CLOSINGTIME}[/MATH])]

=

[THEN]Sorry, registration = closed.[/THEN]

[ELSE]Here's the registration form = ....[/ELSE]

[/IF]

 

 

 

 

Kind regards

 

Stuart Tremain

Pharoah Lane Software

AUSTRALIA

 

 

 

 

 

On 28 Mar 2017, at 08:38, Lawrence Banahan <banahan.l@gmail.com> = wrote:

 

I was adding seconds = to days.
This can't work.
Is there a way to get this = work?

[if = [math]{[todaysdate]}+{[TodaysTIME]}[/math]>[math]{03/26/2017}+{12:00:0= 0}[/math]]
[then]Sorry, registration = closed.<br>[/then]
[else]Here's the registration form = ....<br>[/else]
[/if]

27 mars = 2017 22:37

I think = this is what you want:

[if = [math]{[date]}[/math]>[math]{03/26/2017}[/math]]
[then]Sorry, = registration closed.[/then]
[else]Here's the registration form = ....[/else]
[/if]

Regards,
Kenneth Grome
WebDNA = Solutions
http://www.webdnasolutions.com
Web Database = Systems and Linux Server = Administration

-------------------------------------------------= --------
This message is sent to you because you are subscribed = to
the mailing list <talk@webdna.us>.
To unsubscribe, E-mail = to: <talk-leave@webdna.us>
archives: http://mail.webdna.us/list/talk@webdna.us
Bug = Reporting: support@webdna.us

=

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug = Reporting: support@webdna.us

=

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug = Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

 

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

-------------------------------------------------------= -- This message is sent to you because you are subscribed to the mailing = list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/= list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us ------=_NextPart_001_01A8_01D2A7A6.E2E872E0-- ------=_NextPart_000_01A7_01D2A7A6.E2E872E0 Content-Type: image/jpeg; name="image001.jpg" Content-Transfer-Encoding: base64 Content-ID: /9j/4AAQSkZJRgABAQEARwBHAAD/2wBDAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQECAQEB AQEBAgICAgICAgICAgICAgICAgICAgICAgICAgICAgL/2wBDAQEBAQEBAQICAgICAgICAgICAgIC AgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgL/wAARCAAZABkDAREA AhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAABgcICQr/xAA0EAABAwMCAgUKBwAAAAAAAAACAQME BQYRABITIQcUMUF2CBUXIjI2N0JRtVRWkZOV0dL/xAAYAQEAAwEAAAAAAAAAAAAAAAADAAEEAv/E ACQRAAICAAQGAwAAAAAAAAAAAAABAhEDMrHREyExM0FxgfDx/9oADAMBAAIRAxEAPwDuEt+gW/UL et6oVC3rfqNQqFv0OfPn1GhUqfOmzZtKZlS5UqZMaNwzNwiJVIl7eXLCaZIGwBl3TY8epPx2+jy2 ZNPjvkwc9uhW8j7nCPhvOsQliYIeS7cvCpp8o50qwrC4v3lsNSDbdmTEhvs2tahxpfV3WnmbbozJ Ew/gwdadbYExVRXKEKoSdvJcaOSqxE7/AAiX0gXx+a69/JSf9alIlste0VzaNpeFrcT9KKymotyi aZ0KRCnzacoE7Kjzn4gi2KqUh3jqDHDHv4mRUfruTWlMzlVUKIVNp9GguEJnAh0+IZjyAiisgyRD nu5azS8miKqjOTVkKqS/psG37fo1Fbabeg25b8eZPeFJBBJSjMG5HjMeyihnaauZwe4OGiju13GA cpOwBeN+U8/IkGbsiS8b7ryogmbzhbyc9REROfZhERO5ETShjPtvpGqTUyLErytS4siSwx5x2tRH 4hPOI0DkjZtaJtFxuVEbIUUiyeNujlBUJGbJN6nM/Cyf2Hf60YgjvKA+NPSP4gT7axpcPtr51YWJ nYn9dnAQWl722p4ot37yzqnlfp6FrqbwawG8/9k= ------=_NextPart_000_01A7_01D2A7A6.E2E872E0-- . "Terry Nair"

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:

Part 2 - [showif] if variable exists (1998) &max= (2003) possible, WebCat2.0 and checkboxes-restated (1997) [input] [/input] (1997) Frames and WebCat (1997) RE: E-mailer error codes (1997) WebDNA deletes major DB data big time (2004) Triggers (2003) [if] and [showif] (2002) select multiple (1997) listfiles shows invisible files ... (1999) Requiring that certain fields be completed (1997) Country & Ship-to address & other fields ? (1997) Field Totals (2004) F3 crashing server (1997) Date Question (2002) Upgrading old WebCat Database Files (1997) unable to launch acgi in WebCat (1997) WebCatb15 Mac CGI -- [purchase] (1997) Resume Catalog ? (1997)