« Newer Snippets
Older Snippets »
1 total  XML / RSS feed 

XSLT and XHTML DTD's

A quick code snippet to include the right XHTML DTD in your XSL generated output. This took me a bit of reseach to find out:

<xsl:output 
method="xml" 
encoding="utf-8" 
omit-xml-declaration="yes" 
indent="no" 
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" 
doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN" />


Another tidbit I found today was:


exclude-result-prefixes="media"

to exclude unwanted namespace declarations from the output.
« Newer Snippets
Older Snippets »
1 total  XML / RSS feed