xsl-list
[Top] [All Lists]

Re: [xsl] XSLT2 - Schema root element to DTD root element

2010-01-19 10:49:08


This is a very basic Faq, by adding a namespace you have changed the
name of your input elements.

<hov:template match="report">


matches report in no-namespace but your report is in
"http://xml.smg-uk.com/schema/cases/report

so it does not match.

Either add

xmlns:r="http://xml.smg-uk.com/schema/cases/report";

to xsl:stylesheet and add r: prefix to all relevant patterns and xpath
eg


<hov:template match="r:report">

or, since you are using xslt 2, you could set the
xpath-default-namespace="http://xml.smg-uk.com/schema/cases/report";
again on xsl:stylesheet (or hov:stylesheet for you)

David



David

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>