6.1 Background
- XSLT is a transformation language for XML documents
- XSLT stylesheets are XML documents
- A stylesheet consists of a set of template rules
- Each template rule provides a pattern specifying where the template
applies
- The matching patterns are specified in terms of XPath.
- XSLT carries the namespace http://www.w3.org/1999/XSL/Transform
<?xml version="1.0" encoding="utf-8" ?>
<!-- template rule -->
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>
<xsl:template match="pattern-1" >
template-1
</xsl:template>
<xsl:template match="pattern-2" >
template-2
</xsl:template>
...........
</xsl:stylesheet>