I recently had a requirement to read in an XSLT file and transform it using Python.
libxml2 python xmlGenerating XML is easy to get wrong. Unescaped entities, mismatched tags, Unicode characters create a minefield for a developer. XHTML is a subset of XML so the same rules apply, however I've noticed not many "web frameworks" generate guaranteed pure XHTML.
python xmlIf you're working with XSL as a templating system, you'll want it to include the correct DTD.
xhtml xmlI'm lazy. I like a complete separation of back-end code and front end styling - logic in the back end, styling for front end. There are many templating solutions floating around, but most put code in with markup. Fortunately, we have a templating solution which most web developers already know... XSL.
python xml