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/skins/common/xslt/html document2html.xsl
Date Sat, 06 Sep 2003 14:22:27 GMT
jefft       2003/09/06 07:22:27

  Modified:    src/resources/skins/common/xslt/html document2html.xsl
  Log:
  Oops, reapply minitoc fix
  
  Revision  Changes    Path
  1.27      +17 -15    xml-forrest/src/resources/skins/common/xslt/html/document2html.xsl
  
  Index: document2html.xsl
  ===================================================================
  RCS file: /home/cvs/xml-forrest/src/resources/skins/common/xslt/html/document2html.xsl,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- document2html.xsl	6 Sep 2003 14:10:41 -0000	1.26
  +++ document2html.xsl	6 Sep 2003 14:22:27 -0000	1.27
  @@ -129,7 +129,7 @@
   }
   </script>
   
  -</xsl:if>
  +    </xsl:if>
     </xsl:template>
   
     <!-- Generates the PDF link -->
  @@ -335,23 +335,26 @@
     <xsl:template name="minitoc">  
       <xsl:param name="tocroot"/>
       <xsl:param name="depth"/>     
  -    <ul class="minitoc">
  -      <xsl:for-each select="$tocroot/section">
  -        <xsl:call-template name="toclink"/>
  -        <xsl:if test="$depth&lt;$max-depth">
  -          <xsl:call-template name="minitoc">
  -            <xsl:with-param name="tocroot" select="."/>
  -            <xsl:with-param name="depth" select="$depth + 1"/>          
  -          </xsl:call-template>
  -        </xsl:if>      
  -      </xsl:for-each>
  -    </ul>
  +    <xsl:if test="count($tocroot/section) > 0">
  +      <ul class="minitoc">
  +        <xsl:for-each select="$tocroot/section">
  +          <li>
  +            <xsl:call-template name="toclink"/>
  +            <xsl:if test="$depth&lt;$max-depth">
  +              <xsl:call-template name="minitoc">
  +                <xsl:with-param name="tocroot" select="."/>
  +                <xsl:with-param name="depth" select="$depth + 1"/>
  +              </xsl:call-template>
  +            </xsl:if>
  +          </li>
  +        </xsl:for-each>
  +      </ul>
  +    </xsl:if>
     </xsl:template>
   
     <xsl:template name="toclink">
       <xsl:variable name="tocitem" select="normalize-space(title)"/>
       <xsl:if test="string-length($tocitem)>0">
  -      <li>
         <a>
           <xsl:attribute name="href">
             <xsl:text>#</xsl:text>
  @@ -361,7 +364,6 @@
           </xsl:attribute>
           <xsl:value-of select="$tocitem"/>
         </a>
  -      </li>
       </xsl:if>
     </xsl:template>
     
  
  
  

Mime
View raw message