xsl-list
[Top] [All Lists]

Re: [xsl] How do templates get invoked for elements decorated with namespaces?

2006-12-05 06:55:10

it's, a FFFFAQ:-)
google just took me here at random:-)

http://www.biglist.com/lists/xsl-list/archives/200111/msg00772.html

The namespace is part of the name, so adding a namespace in the source
is like changing the name by adding a letter A at the front, and the
changes needed in the xsl are teh same in both cases, you just need to
change the names in the patterns and xpaths to use the same name.

add
 xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
to your xsl:stylesheet then you can refer to elements in this namespace
 by

<xsl:template match="/ss:Workbook"> 

         <xsl:apply-templates select="ss:DocumentProperties" />

--~------------------------------------------------------------------
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>
--~--