home *** CD-ROM | disk | FTP | other *** search
/ 11 Top Anwendungen / CD_ROM_MAGAZIN.iso / MoneyMethod-Demo / Beispiel / source / XML / store.xsl < prev    next >
Encoding:
Extensible Markup Language  |  2000-05-29  |  3.2 KB  |  76 lines

  1. <xsl:stylesheet
  2.   version="1.0"
  3.   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  4.   xmlns:xt="http://www.jclark.com/xt">
  5. <xsl:output method="html"/>
  6. <xsl:strip-space elements="*"/>
  7.  
  8. <xsl:template name="makestore">
  9. <xt:document href="{concat($filepath, 'store.htm')}" method="html">
  10. <html>
  11.   <head>
  12.     <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
  13.     <meta name="GENERATOR" content="E-Shop v2.0a"/>
  14.   <title>Online shop</title>
  15. </head>
  16.  
  17. <xsl:variable name="uframe-size"
  18.   select="$uframe-st/param[@name="size"]/@value"/>
  19. <xsl:variable name="lframe-size"
  20.   select="$lframe-st/param[@name="size"]/@value"/>
  21. <xsl:variable name="uframe-sizable">
  22.   <xsl:if test="$uframe-st/param[@name="sizable"]/@value = "true"">resize</xsl:if>
  23.   <xsl:if test="$uframe-st/param[@name="sizable"]/@value = "false"">noresize</xsl:if>
  24. </xsl:variable>
  25. <xsl:variable name="lframe-sizable">
  26.   <xsl:if test="$lframe-st/param[@name="sizable"]/@value = "true"">resize</xsl:if>
  27.   <xsl:if test="$lframe-st/param[@name="sizable"]/@value = "false"">noresize</xsl:if>
  28. </xsl:variable>
  29. <xsl:variable name="uframe-scrollable">
  30.   <xsl:if test="$uframe-st/param[@name="scrollable"]/@value = "true"">auto</xsl:if>
  31.   <xsl:if test="$uframe-st/param[@name="scrollable"]/@value = "false"">no</xsl:if>
  32. </xsl:variable>
  33. <xsl:variable name="lframe-scrollable">
  34.   <xsl:if test="$lframe-st/param[@name="scrollable"]/@value = "true"">auto</xsl:if>
  35.   <xsl:if test="$lframe-st/param[@name="scrollable"]/@value = "false"">no</xsl:if>
  36. </xsl:variable>
  37.  
  38. <frameset rows="{$uframe-size},{$lframe-size}" border="0">
  39.    <xsl:element name="frame">
  40.       <xsl:attribute name="src">catlist.htm</xsl:attribute>
  41.     <xsl:attribute name="frameborder">0</xsl:attribute>
  42.     <xsl:attribute name="marginheight">0</xsl:attribute>
  43.     <xsl:attribute name="marginwidth">0</xsl:attribute>
  44.     <xsl:attribute name="name">shop</xsl:attribute>
  45.     <xsl:attribute name="scrolling"><xsl:value-of select="$uframe-scrollable"/></xsl:attribute>
  46.         <xsl:if test="$uframe-st/param[@name="sizable"]/@value = "false"">
  47.         <xsl:attribute name="noresize"/>
  48.         </xsl:if>
  49.   </xsl:element>
  50.    <xsl:element name="frame">
  51.     <!-- 
  52.     <xsl:choose>
  53.     <xsl:when test="$preview != 'yes'">
  54.     <xsl:attribute name="src">storeinf.htm</xsl:attribute>
  55.     </xsl:when>
  56.     <xsl:otherwise>
  57.            <xsl:attribute name="src">tcat11.htm</xsl:attribute>
  58.     </xsl:otherwise>
  59.     </xsl:choose>
  60.     -->
  61.          <xsl:attribute name="src">tcat11.htm</xsl:attribute>
  62.     <xsl:attribute name="frameborder">0</xsl:attribute>
  63.     <xsl:attribute name="name">content</xsl:attribute>
  64.     <xsl:attribute name="marginheight">0</xsl:attribute>
  65.     <xsl:attribute name="marginwidth">0</xsl:attribute>
  66.     <xsl:attribute name="scrolling"><xsl:value-of select="$lframe-scrollable"/></xsl:attribute>
  67.         <xsl:if test="$lframe-st/param[@name="sizable"]/@value = "false"">
  68.         <xsl:attribute name="noresize"/>
  69.         </xsl:if>
  70.   </xsl:element>
  71. </frameset>
  72. </html>
  73. </xt:document>
  74. </xsl:template>
  75.  
  76. </xsl:stylesheet>