[pmwiki-users] Re: Conditional Directive based on time - standards
chr at home.se
chr at home.se
Thu Oct 13 12:31:45 CDT 2005
On Thu, 13 Oct 2005, Neil Herber wrote:
> >To be consistent with the (:include:) markup, I'm also thinking that
> >we should specify ranges with "..", thus
> >
> > (:if date 20051014..20051020:) Oct 14 through Oct 20
> > (:if date 20051014..:) On or after Oct 14
> > (:if date ..20051020:) On or before Oct 20
>
> These are excellent - compact, easy to read, and unambiguous.
I haven't really followed this thread, but how about
(:if 20051014 < date < 20051020:)
(:if 20051014 <= date <= 20051020:)
where instead of 'date' we could alternatively use 'now' or 'time'?
/Christian
PS. Perhaps it should be {$now}, but then
(:if 20051014 < {$now} < 20051020:)
might look too much as if the condition accepts a general expression?
--
Christian Ridderström, +46-8-768 39 44 http://www.md.kth.se/~chr
More information about the pmwiki-users
mailing list