Moving Towards Interweb Nirvana
Well it seems that I caused some sort of a stir with yesterday’s post about Mark’s fiasco. Don’t get me wrong; I love reading Mark, and my comments weren’t meant in a mean fashion.
What I was trying to get at, was that it seems to me that Mark needs a little bit more leeway with his online publishing. He seemed happy using XHTML 1.1, and then he toyed with the idea of having to migrate to XHTML 2.0, and was not happy.
Yesterday, I proposed mark use a “presentation layer”. This is just a fancy way of saying that he needs a better separation of his content and his layout. Sure, he uses XHTML + CSS + MT with a database backend, but apparently that’s not enough.
Mark needs the ability to store his data however he wants, and then spit out HTML, XML, or whatever his heart (or his reader’s hearts) desire. This is where Cocoon comes in, and this is where I plan on getting some work done with connecting Cocoon and MT together in a useful fashion.
One of the problems with how MT works is that it stores everything in the database, and then exports it to whatever format using the templates.
- Editing templates in a textarea sucks
- Where are the XML templates?
- Why doesn’t MT’s export do so as XML?
And most importantly,
I am working on a Python script to convert MT’s loosely-structured export output to well-formed XML. This will be useful when I want to pull all of the entries into Cocoon.
Another option is to manually edit the MT templates to output XML, and then serve them up using Cocoon.
Why Cocoon?
- I can use some sort of XML DTD that I know won’t change very much (DocBook, Apache Document v1.1).
- I can output to any number of formats, and I can very easily serve up a “lite” page for older browsers or users who so desire.
- I’m not screwed when the W3C releases another XHTML 2.0 spec.
- I know my data won’t be changing whenever the W3C changes their mind about how data should be presented as (X)HTML.
So there you have it. Think about it. It looks like MT is getting something that looks like you can use Wikiesque commands, but then when I saw the Perl code that handled it, I ran away screaming.
Stay tuned.