The following diagram is meant to illustrate the XSLT process:
The are some important points in the process.
First the XML document is read hierarchically, as a
tree structure. Instead of drawing a normal tree our
illustration is turned 90 degrees counter clockwize so
that reading from top to bottom is the hierarchical
order.
Secondly the rules of the XSLT must be organised so
that when some node from the XML must induce some
output, your XSLT must find it with an XPATH expression
in a template match="..." where the dots
are the XPATH.
In the example you will notice that we want an HTML5
document as output, then we make a rule so that when
the XML root is met, we create an HTML5 outline with
an apply-templates thus creating a rule
that we will detail further down in the XSLT.
It would be beneficial to look at the solution examples
to the XSLT assignments we made for example with
the "letter to mum".