To do anything significant with XSLT, you must work with the XML Path Language (XPath). XPath is a W3C Recommendation that is used for identifying elements, attributes, text and other nodes within an XML document. XPath looks at an XML document as a tree. Each element is a branch that may have branches of its own.
In XSLT, XPath is used to match nodes from the source document for output templates via the
match attribute of the
XPath is also used in the
xsl:value-of tag to specify elements, attributes and text to decide what to output.
In addition, XPath is used in conditionals and flow control statements, which is covered in the lesson on Flow Control.