I've recently had to write a web frontend to a trivial one table database for The Day Job.
I asked a couple of times if I could use Java, which I'm much more familiar with, but I was, shall we say, encouraged to use Perl instead. In the spirit of making lemons from lemonade, I took this little project as an opportunity to learn the Catalyst web framework.
And although Catalyst isn't the easiest thing to learn, for a while there things seemed to be going down smooth. Defining the object relational mapping was a matter of dozen lines of code or so. Using FormFu, I could define the form in a couple of dozen lines of YAML markup in a configuration file and get validation and error messages and so on automagically.
Deploying my freshly minted little Catalyst application to run as a CGI script on Solaris was quick and easy too, requiring only a couple of days of intense mental effort and building a whole new perl interpreter from scratch while reciting the mystic incantations required to make it 64 bit, and then installing all the various CPAN modules required to make it work.
Having broken the back of the project and got it basically working, it was then time to go back and fix the little things. Like date formats.
In the first cut of the application, dates displayed as "2008-01-01", which is some kind of ISO or IEEE standard or something.
"Right," thought I, flush with the success of my battles with CPAN on Solaris, and lulled into a false sense of security by the deceitful veneer of efficiency and simplicity of Catalyst and FormFu, "This should be simple. After all, everyone needs to pull dates out of a database and display them prettily formatted on a web page. It's such a common thing to have to do, it's probably just an entry in one of the config files somewheres..."
Two, or perhaps three, days pass...
I won't bore you with a catalogue of all the different things I've tried to get these dates to display in dd/mm/yyyy format, or a list of the CPAN modules I've installed, or the tutorials and documentation read, or the profanities uttered.
Once again we discover that black magic is alive and well in the 21st century. And like magicians of old, the practitioners of this modern black art find that even once they have wrested the book of spells from the clutches of a fire breathing fell beast of evil odour; and translated the strange inscriptions; and gathered all the rare and mysterious compounds the magic requires...
nothing works!