forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sergey Missan <ad...@javable.com>
Subject suppressing index.html
Date Wed, 05 Mar 2003 02:39:00 GMT
Hello,

I was playing a bit more with Forrest and tried to suppress generation
of .../index.html links in menus (but still keeping them in site.xml).

I've changed the code in skins/common/book2menu.xsl to:

  <xsl:template name="unselected">
  <xsl:choose>
   <xsl:when test="contains(@href,'index.html')">
    <xsl:variable name="dir">
      <xsl:call-template name="dirname">
        <xsl:with-param name="path" select="@href"/>
      </xsl:call-template>
    </xsl:variable>
     <a href="{$dir}"><xsl:value-of select="@label"/></a>
   </xsl:when>
   <xsl:otherwise>
     <a href="{@href}"><xsl:value-of select="@label"/></a>
   </xsl:otherwise>
  </xsl:choose>
  </xsl:template>

and this stopped forrest from generating my files containing index.html
in their names! My understanding was that book2menu.xsl takes site.xml
or book.xml as a source and generates the navigational stuff. Now it
looks like it has a mind of its own?

-- Sergey



Mime
View raw message