[pmwiki-users] repost: problem with PTV and if= date in pagelists

Peter Bowers pbowers at pobox.com
Thu Jan 29 00:06:09 CST 2009

On Thu, Jan 29, 2009 at 2:45 AM, none < <bergwitz at gmail.com> wrote:

> If the code worked on Peter Bowers wiki, why won't it work on ours. Can
> somebody else test to see if it's work. Maybe there's something wrong
> with our setup somehow?

Try this:


nowyyyymmdd:{(ftime %Y%m%d)}
(:pagelist name=Test.? if="date {*$:nowyyyymmdd}.. {=$:Timestamp}"

(:pagelist name=Test.? if="date {(ftime %Y%m%d)}.. {=$:Timestamp}"

(:pagelist name=Test.? if='date ..{=$:Timestamp}' $:Timestamp=-:)


Previously I was using a "name=Test.[A-D]" to limit my pagelist processing
to just the 4 files I had set $:Timestamp on.  When I broadened it to
include pages without that PTV set then my pagelist also included those
pages.  Now you'll note in each of the examples above that I've included the
"$:Timestamp=-" to get rid of pages without a $:Timestamp.

Note that Patrick's solution, the 3rd one above, is the only one that
properly handles "recognizable dates".  The others recognize only a limited
set of formats such as 2009-01-29 or 01/29/2009 but not "January 29, 2009"
in the PTV.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20090129/c670090b/attachment-0001.html 

More information about the pmwiki-users mailing list