forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From je...@apache.org
Subject cvs commit: xml-forrest/src/resources/library/xslt docbook2document.xsl
Date Sat, 08 Mar 2003 07:14:38 GMT
jefft       2003/03/07 23:14:38

  Modified:    src/resources/library/xslt docbook2document.xsl
  Log:
  Add support for Docbook 'article' type. Thanks to kho braun <kho @ pobox.com>
  
  Revision  Changes    Path
  1.5       +22 -1     xml-forrest/src/resources/library/xslt/docbook2document.xsl
  
  Index: docbook2document.xsl
  ===================================================================
  RCS file: /home/cvs/xml-forrest/src/resources/library/xslt/docbook2document.xsl,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- docbook2document.xsl	6 Mar 2003 13:30:58 -0000	1.4
  +++ docbook2document.xsl	8 Mar 2003 07:14:37 -0000	1.5
  @@ -14,7 +14,7 @@
         <xsl:output method="xml" indent="yes" doctype-system="http://localhost/forrest/dtd/document-v11.dtd"
doctype-public="-//APACHE//DTD Documentation V1.1//EN" encoding="UTF-8"/>
   
         <xsl:template match="/">
  -            <xsl:apply-templates select="book|chapter|revhistory"/>
  +            <xsl:apply-templates select="book|chapter|revhistory|article"/>
         </xsl:template>
   
         <xsl:template match="/book">
  @@ -56,6 +56,27 @@
                     </body>
               </document>
         </xsl:template>
  +
  +       <xsl:template match="/article">
  +             <document>
  +                   <header>
  +                         <xsl:apply-templates select="articleinfo/title"/>
  +                         <xsl:apply-templates select="articleinfo/subtitle"/>
  +                         <authors>
  +                               <xsl:apply-templates select="articleinfo/author"/>
  +                               <xsl:apply-templates select="articleinfo/corpauthor"/>
  +                         </authors>
  +                   </header>
  +                   <body>
  +                         <xsl:apply-templates select="node()[
  +                               local-name() != 'title' and
  +                               local-name() != 'subtitle' and
  +                               local-name() != 'articleinfo'
  +                               ]"/>
  +                         <xsl:call-template name="apply-footnotes"/>
  +                   </body>
  +             </document>
  +       </xsl:template>
   
         <xsl:template name="apply-footnotes">
               <xsl:if test="//footnote">
  
  
  

Mime
View raw message