00975: (:if date:) inconsistent with page variables
Summary:
(:if date:)
inconsistent with page variablesCreated: 2007-09-11 11:01
Status: Closed - not a bug
Category: Bug
From: JonHaupt
Assigned:
Priority: 5
Version: 2.2 beta
OS:
Description: I have created a page variable called BlogDate2 which produces the page's creation time in the format YYYY-MM-DD.
I'm confused by how this page variable works with (:if date:)
.
Assuming I created the page today:
(:if date yesterday..tomorrow:)
this is true.(:if date "-1 month"..tomorrow:)
this is true.(:if date yesterday..tomorrow {*$BlogDate2}:)
this is true.(:if date "-1 month"..tomorrow {*$BlogDate2}:)
this is not true.
{(ftime when=today fmt="%F")} * BlogDate2 is "{$:BlogDate2}" * true false * true false * true false * true false * true false |
BlogDate2:2025-05-29
|
Try eliminating the spaces from "-1 month" or using something like "-30days":
{(ftime today %F)} * true false * true false |
BlogDate3:2025-05-29
|
--Pm
ah, how intriguing. well, that does seem to work. Thanks!