[pmwiki-users] pagevariable for creation time

Patrick R. Michaud pmichaud at pobox.com
Wed May 9 13:27:08 CDT 2007


On Wed, May 09, 2007 at 01:18:42PM -0500, Jon Haupt wrote:
> On 5/8/07, Patrick R. Michaud <pmichaud at pobox.com> wrote:
> >Try:
> >
> >  $FmtPV['$Created'] = "strftime(\$GLOBALS['TimeFmt'], \$page['ctime'])";
> >
> >Pm
> >
> 
> What would you do if you wanted to format the ctime using markup 
> expressions?
> 
> Is it actually possible to use a page variable as the "when" in
> {(ftime)} expressions?

We likely want to create some page variables for this.  Of course,
if a page's name already has a date of some sort in it, then one
can do:

    {(ftime {$Name})}

But I'm thinking we might want to have *ISO versions of the
various date/time expressions.  I'm still coming up with names
for these.  My best guess at the moment is one of:

    {$LastModifiedISO}            # output form yyyy-mm-ddThh:mm:ss
    {$CreatedISO}                 

or 

    @{$mtime}                     # output as @1178735110
    @{$ctime}                     

Either of these would then work as inputs to {(ftime)}.

Suggestions welcomed.

Pm




More information about the pmwiki-users mailing list