Documentation >> Conditionals >> date >> date.now
Conditional Macro: date.now
Operators:
- == (equal to)
- != (not equal to)
- greaterThan
- greaterThanOrEqualTo
- lessThan
- lessThanOrEqualTo
Usage Notes
- For use in testing date values generated by other conditional macros against the current time. date.now will simply return the current date/time in GMT.
Examples
This example demonstrates how to use date.now to display text only of the the current value of a date-type cookie is in the future:
<!--#if condition="cookie.[cookieName].toDate >= date.now"-->
Display this text
<!--#endIf-->
View in DG
|