home *** CD-ROM | disk | FTP | other *** search
/ Internet Magazine 2003 October / INTERNET108.ISO / pc / software / windows / building / xmlspy / xmlspyentcomplete5.exe / Data1.cab / _FAACF1EA66EA49A89F82ACF21FFA110D < prev    next >
Encoding:
Extensible Markup Language  |  2002-09-04  |  2.8 KB  |  73 lines

  1. <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  2.                 xmlns:doc="http://nwalsh.com/xsl/documentation/1.0"
  3.         version="1.0"
  4.                 exclude-result-prefixes="doc">
  5.  
  6. <xsl:template name="generate.manifest">
  7.   <xsl:param name="node" select="/"/>
  8.   <xsl:call-template name="write.text.chunk">
  9.     <xsl:with-param name="filename" select="$manifest"/>
  10.     <xsl:with-param name="method" select="'text'"/>
  11.     <xsl:with-param name="content">
  12.       <xsl:apply-templates select="$node" mode="enumerate-files"/>
  13.     </xsl:with-param>
  14.     <xsl:with-param name="encoding" select="$chunker.output.encoding"/>
  15.   </xsl:call-template>
  16. </xsl:template>
  17.  
  18. <xsl:template match="set|book|part|preface|chapter|appendix
  19.                      |article
  20.                      |reference|refentry
  21.                      |sect1|sect2|sect3|sect4|sect5
  22.                      |section
  23.                      |book/glossary|article/glossary
  24.                      |book/bibliography|article/bibliography
  25.                      |book/index|article/index
  26.                      |colophon"
  27.               mode="enumerate-files">
  28.   <xsl:variable name="ischunk"><xsl:call-template name="chunk"/></xsl:variable>
  29.   <xsl:if test="$ischunk='1'">
  30.     <xsl:call-template name="make-relative-filename">
  31.       <xsl:with-param name="base.dir" select="$base.dir"/>
  32.       <xsl:with-param name="base.name">
  33.         <xsl:apply-templates mode="chunk-filename" select="."/>
  34.       </xsl:with-param>
  35.     </xsl:call-template>
  36.     <xsl:text> </xsl:text>
  37.   </xsl:if>
  38.   <xsl:apply-templates select="*" mode="enumerate-files"/>
  39. </xsl:template>
  40.  
  41. <xsl:template match="legalnotice" mode="enumerate-files">
  42.   <xsl:variable name="id"><xsl:call-template name="object.id"/></xsl:variable>
  43.   <xsl:if test="$generate.legalnotice.link != 0">
  44.     <xsl:call-template name="make-relative-filename">
  45.       <xsl:with-param name="base.dir" select="$base.dir"/>
  46.       <xsl:with-param name="base.name" select="concat('ln-',$id,$html.ext)"/>
  47.     </xsl:call-template>
  48.     <xsl:text> </xsl:text>
  49.   </xsl:if>
  50. </xsl:template>
  51.  
  52. <xsl:template match="mediaobject[imageobject] | inlinemediaobject[imageobject]" mode="enumerate-files">
  53.   <xsl:variable name="longdesc.uri">
  54.     <xsl:call-template name="longdesc.uri">
  55.       <xsl:with-param name="mediaobject"
  56.                       select="."/>
  57.     </xsl:call-template>
  58.   </xsl:variable>
  59.   <xsl:variable name="mediaobject" select="."/>
  60.  
  61.   <xsl:if test="$html.longdesc != 0 and $mediaobject/textobject[not(phrase)]">
  62.     <xsl:call-template name="longdesc.uri">
  63.       <xsl:with-param name="mediaobject" select="$mediaobject"/>
  64.     </xsl:call-template>
  65.     <xsl:text> </xsl:text>
  66.   </xsl:if>
  67. </xsl:template>
  68.  
  69. <xsl:template match="text()" mode="enumerate-files">
  70. </xsl:template>
  71.  
  72. </xsl:stylesheet>
  73.