I am doing a very simple xslt to convert a html page to a xml file.
But it appears to me that the starting point is not that straightforward to me.My first goal is t
XSLT 1.0:
Try adding xmlns:x="http://www.w3.org/1999/xhtml"
to your xsl:stylesheet
and changing your match to match="x:html"
. (Note: you don't have to use "x"; you can choose anything you want.)
XSLT 2.0:
Either use the above method or replace the namespace prefix in your match(es) to "*" (match="*:html"
). You could also add xpath-default-namespace="http://www.w3.org/1999/xhtml"
to the xsl:stylesheet
.