Project

Profile

Help

excluding result prefix

Added by Anonymous about 16 years ago

Legacy ID: #5308767 Legacy Poster: Fredster (fredchristian)

I'm stuck while trying to exclude some namespaces, and I admit that I am feeling over my head at the moment so I am not sure how to ask this question of what additional info is relevant. xslt code snippet: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="2.0" xmlns="http://www.w3.org/1999/xhtml" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://saxon.sf.net/" xmlns:kml="http://tempuri.org/BookDefinition.xsd" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:ksp="http://www.w3.org/1999/xhtml" exclude-result-prefixes="kml xsl m" extension-element-prefixes="saxon" xmlns:alias="alias-namespace" > {lots of stuff} <xsl:template match="msup" mode="addonencode"> <mo xsl:exclude-result-prefixes="#all"><xsl:text> </xsl:text></mo><xsl:copy> <xsl:apply-templates mode="addonencode"/></xsl:copy><mo xsl:exclude-result-prefixes="#all"><xsl:text> </xsl:text></mo> </xsl:template> {lots of stuff} Result xml output snippet: <mo xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml&quot;&gt;TEST&lt;/mo&gt;&lt;otherstuff/&gt;&lt;mo xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="http://www.w3.org/1999/xhtml&quot;&gt;END&lt;/mo> Desired result xml output snippet: <mo>TEST</mo><otherstuff/><mo>END</mo> I have a huge amount of XSLT ( >3000 lines in multiple files). And the source and output is in the 100's of kbytes, so it isn't applicable to send it all. I suppose a debugging step would be to try and reduce everything to bare minimum and still get a repro. By chance is there enough here to give me some hints?


Replies (2)

RE: excluding result prefix - Added by Anonymous about 16 years ago

Legacy ID: #5309733 Legacy Poster: Michael Kay (mhkay)

A good place to get XSLT programming help is the xsl-list at mulberrytech.com. This forum is for reporting problems specific to the Saxon product. I help when I can but I'm a bit tied up at the moment.

RE: excluding result prefix - Added by Anonymous about 16 years ago

Legacy ID: #5312148 Legacy Poster: Fredster (fredchristian)

Thanks much for the pointer.

    (1-2/2)

    Please register to reply