From f850acc6ad8a780a6b913df1099b8563647de03d Mon Sep 17 00:00:00 2001 From: joey Date: Thu, 15 Feb 2007 05:48:40 +0000 Subject: * Patch from Ethan to allow using meta tags to set creation dates of pages. --- IkiWiki/Plugin/meta.pm | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'IkiWiki/Plugin') diff --git a/IkiWiki/Plugin/meta.pm b/IkiWiki/Plugin/meta.pm index 2e5fd7e76..5867329af 100644 --- a/IkiWiki/Plugin/meta.pm +++ b/IkiWiki/Plugin/meta.pm @@ -61,6 +61,13 @@ sub preprocess (@) { #{{{ $permalink{$page}=$value; $meta{$page}.="\n"; } + elsif ($key eq 'date') { + eval q{use Date::Parse}; + if (! $@) { + my $time = str2time($value); + $IkiWiki::pagectime{$page}=$time if defined $time; + } + } else { $meta{$page}.="\n"; -- cgit v1.2.3