Dear List,

Today with Catalyst, I have been trying to find the mtime of the top-level
template, so I can put "Updated On: date" in my footer.tt

[% template.modtime %] is what I want, but I am not sure how to convert
from epoch IN the template?

I have also looked at Template::Plugin::Date:

[% USE date %]

[% date.format(filemod_time) %]

But if I put [% USE date %] in my header.tt then [%
date.format(filemod_time) %] in my footer.tt, the time always changes, as
expected. If I put them both in footer.tt, then I only get the mtime of
footer.tt, which is no good ;-)

So I think the best option is to use [% template.modtime %], but how can I
convert from epoch from within a template?

Thanks kindly,

Gavin.

-- 
Walking the road to enlightenment... I found a penguin and a camel on the
way..... Fancy a [EMAIL PROTECTED] Just ask!!!
http://perlmonks.org/?node_id=386673

_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to