home *** CD-ROM | disk | FTP | other *** search
/ PC Professionell 2004 December / PCpro_2004_12.ISO / files / webserver / xampp / xampp-cocoon-addon-1.4.9-installer.exe / dir2html.xsl < prev    next >
Encoding:
Extensible Markup Language  |  2004-07-12  |  1.9 KB  |  55 lines

  1. <?xml version="1.0"?>
  2. <!--
  3.   Copyright 1999-2004 The Apache Software Foundation
  4.  
  5.   Licensed under the Apache License, Version 2.0 (the "License");
  6.   you may not use this file except in compliance with the License.
  7.   You may obtain a copy of the License at
  8.  
  9.       http://www.apache.org/licenses/LICENSE-2.0
  10.  
  11.   Unless required by applicable law or agreed to in writing, software
  12.   distributed under the License is distributed on an "AS IS" BASIS,
  13.   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14.   See the License for the specific language governing permissions and
  15.   limitations under the License.
  16. -->
  17.  
  18. <xsl:stylesheet version="1.0" 
  19.                 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  20.                 xmlns:dir="http://apache.org/cocoon/directory/2.0">
  21.  
  22.   <xsl:template match="dir:directory">
  23.     <samples name="ASCII Art Block Samples" xmlns:xlink="http://www.w3.org/1999/xlink">
  24.       <group name="Back">
  25.         <sample name="Back" href="../..">to Cocoon Samples main page</sample>
  26.         <sample name="Back" href="..">to Cocoon Blocks Samples main page</sample>
  27.       </group>
  28.  
  29.       <group name="Available ascii art TXT files">
  30.         <xsl:apply-templates select="dir:file" mode="txt"/>
  31.       </group>
  32.  
  33.       <group name="ascii art in JPEG">
  34.         <xsl:apply-templates select="dir:file" mode="jpg"/>
  35.       </group>
  36.  
  37.       <group name="ascii art in PNG">
  38.         <xsl:apply-templates select="dir:file" mode="png"/>
  39.       </group>
  40.     </samples>
  41.   </xsl:template>
  42.  
  43.   <xsl:template match="dir:file" mode="txt">
  44.     <sample name="{@name}" href="{@name}">as text</sample>
  45.   </xsl:template>
  46.  
  47.   <xsl:template match="dir:file" mode="jpg">
  48.     <sample name="{@name}" href="{@name}.jpg">as jpg</sample>
  49.   </xsl:template>
  50.  
  51.   <xsl:template match="dir:file" mode="png">
  52.     <sample name="{@name}" href="{@name}.png">as png</sample>
  53.   </xsl:template>
  54. </xsl:stylesheet>
  55.