I know that it's perverse, but XSLT's actually kind of fun if you're not doing anything terribly complex.
So you're saying that XSLT makes the simple things fun and the complex things terrible?
Pretty much. It's certainly more fun than DOM for simple transformations.
Yes, XSLT written in XML itself is abominable. It's easier to read if the program and data have different formats (lisp notwithstanding...). But it's escaping less-than signs that got really me: (i < 5).
But transforming trees with a functional programming approach (not PHP) is a natural fit.
XSLT happens to be my pet peeve. I simply can't understand how anyone would have ever looked at that problem ("how to turn a source data document into a presentation format" -- something that has been solved sanely a thousand times by obscure technologies like "scripts", or "PHP") and decided that the best way to handle it was a turing-complete pattern matching language written in XML itself! I mean, it looks more like a torture device than a programming language...