The Preamble
Once upon a time there was man. This man decided to create a new form of blog syndication, he called it ESF. All was well with ESF until folks tried to use it with MT, much to everyone's disgust the big boys didn't play nicely with our man's new creation. Eventually someone thought this wasn't very nice and decided to see what could be done to make MT and ESF play together nicely. Thus was born MT-Epoch!
But seriously
This is a plugin to help people convert dates into seconds since Epoch (1st January 1970) which probably has many purposes, but mainly it was written to stop Aquarion moaning about lack of support for ESF :-)
Yes this is pointless; therefore I get to call it fun. Now leave me alone!
The gory details
- Get a copy of Time::ParseDate (this can also be found in the Time-modules MegaPack) If you're deprived this as part of your server then you should be able to put a copy in the ExtLib directory and away you go.
- Then you need a copy of MT-Epoch.pl in your MT-Plugins directory.
- You can now add the argument convert_to_epoch="1" to any tag you like, although to be honest it's pretty pointless using it for anything but a date.
This module has been tested with Perl 5.005 and MT 2.64, in other words it worked for me. If you use it and the world crumbles around you don't blame me. In fact don't blame me for anything, ever, you got that?
What the ESF?
If, like me, you want a super funky ESF feed then you'll need to create a new index template. Bearing in mind my usual disclaimer this is what I use:
#<$MTBlogName$> Newsfeed, in Episula Syndication Feed format (ESF) #http://www.aquarionics.com/article/name/esf title <$MTBlogName$> contact edit@your.self (Don't forget your name in here too) link <$MTBlogURL$> <MTEntries lastn="10"> <MTEntryDate format="%Y/%m/%d %H:%M:%S" convert_to_epoch="1"> <$MTEntryTitle$> <$MTEntryPermalink$> </MTEntries>
Please note that the entry details are tab-delimited. You can download a copy if you like, just edit the contact details and you're away.
This plugin is listed at mt-plugins.org where there's more room for feedback until I make an effort with this stuff.