[pmwiki-devel] (:if date:) page variables quandary
Patrick R. Michaud
pmichaud at pobox.com
Tue Oct 16 15:33:26 CDT 2007
On Tue, Oct 16, 2007 at 01:58:36PM -0500, Jon Haupt wrote:
> I am trying to set up a comment box that only appears when the
> creation time for the post in question was less than 1 month from the
> current date. The problem is that page variables cannot be used in an
> (:if date:) directive.
>
> http://www.pmwiki.org/wiki/PITS/00975
Yes, page variables can be used in (:if date:) directives.
The problem is that PmWiki (or the strftime function) is having
trouble parsing "-1 month" as a date. Try "-1month" or "-30days"
instead.
See the example I posted to the PITS page that appears to work
properly.
Pm
More information about the pmwiki-devel
mailing list