xsl-list
[Top] [All Lists]

Re: [xsl] Moving Specific content/element to the end of the output file

2009-10-06 08:23:09
Ramkumar wrote:

In my input xml file, element 'footnote' may come any where in my xml
structure. There is specific parent element for this, common root element is
'doc'.
I will try to move all the footnotes to the end of the output file.

Consider to post a small input sample and the corresponding HTML you want the stylesheet to create.
If you want to move all footnotes to the end then you probably want e.g.

<xsl:template match="doc">
  <html>
    <head>
    </head>
    <body>
      <xsl:apply-templates/>
      <xsl:apply-templates select="//footnote" mode="m1"/>
    </body>
  </html>
</xsl:template>

<xsl:template match="footnote"/>

<xsl:template match="footnote" mode="m1">
  <!-- now output what you want to do with footnotes here -->
</xsl:template>

and then add templates for the default mode that copy or transform the elements you want in the HTML document before listing the footnotes at the end.





--

        Martin Honnen
        http://msmvps.com/blogs/martin_honnen/

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