home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 May / CHIP_CD_2003-05.iso / software / jpspa / files / ppa400ev.exe / Data1.cab / single.xsl35 < prev    next >
Encoding:
Extensible Markup Language  |  2003-02-17  |  5.0 KB  |  122 lines

  1. <?xml version="1.0"?>
  2. <!-- Copyright (C) 1995-2003 Jasc Software, Inc. and its licensors. -->
  3. <!-- All rights reserved. -->
  4. <!DOCTYPE xsl:stylesheet [
  5.     <!ENTITY externalScript SYSTEM "../ScriptLib/common.xsl">
  6. ]>
  7. <xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">
  8. &externalScript;
  9.     <xsl:template match="/">
  10.         <HTML>
  11.             <xsl:apply-templates/>
  12.         </HTML>
  13.     </xsl:template>
  14.     <xsl:template match="photos">
  15.         <xsl:apply-templates/>
  16.     </xsl:template>
  17.     <xsl:template match="album">
  18.         <xsl:apply-templates select="imagelist"/>
  19.     </xsl:template>
  20.     <xsl:template match="imagelist">
  21.         <xsl:apply-templates select="imageinfo"/>
  22.     </xsl:template>
  23.     <xsl:template match="imageinfo">
  24.         <xsl:element name="ixfile">
  25.             <xsl:attribute name="fname"><xsl:value-of select="html_info/@fname"/></xsl:attribute>
  26.             <head>
  27.                 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
  28.             </head>
  29.             <BODY bgcolor="#000000">
  30.             <table width="800" border="6" cellspacing="6" cellpadding="6" bgcolor="#000000" align="center">
  31.               <tr>
  32.                 <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
  33.                     <tr>
  34.                         <td valign="top" bgcolor="#FFFFFF" width="30%">
  35.                             <div align="center">
  36.                             <br kludge=""/>
  37.                             <br kludge=""/>    
  38.                              <p><font face="Arial, Helvetica, sans-serif" size="2"><b><xsl:eval>GetAlbumTitle()</xsl:eval></b>
  39.                                 </font></p>
  40.                                     <p><font face="Arial, Helvetica, sans-serif" size="2"><xsl:apply-templates select="next"/></font></p>
  41.                                     <p><font face="Arial, Helvetica, sans-serif" size="2"> <xsl:apply-templates select="previous"/> 
  42.                             </font></p>
  43.                              <p><font face="Arial, Helvetica, sans-serif" size="2"><br kludge="" /><a href="index.htm">Home</a></font></p>
  44.                                     <p><br kludge=""/>
  45.                                     <br kludge=""/>
  46.                                   <br kludge=""/>
  47.                                   <br kludge=""/>
  48.                                   <br kludge=""/>
  49.                                   </p></div></td>
  50.                             <td  bgcolor="#FFFFFF" valign="middle"><div align="center"><IMG border="1"><xsl:attribute name="src"><xsl:value-of select="@fname"/></xsl:attribute>
  51.                         <xsl:attribute name="width"><xsl:value-of select="imagesize/@width"/></xsl:attribute>
  52.                         <xsl:attribute name="height"><xsl:value-of select="imagesize/@height"/></xsl:attribute>
  53.                         <xsl:attribute name="alt"><xsl:value-of select="title"/></xsl:attribute>
  54. </IMG></div></td>
  55.                       </tr>
  56.                <tr bgcolor="#FFFFFF"> 
  57.                             <td><div align="center"><xsl:choose>
  58.                             <xsl:when test="audio_info/@fname[. != '']">
  59.                                 <div align="center">
  60.                                         <xsl:apply-templates select="audio_info"/></div>
  61.                                 </xsl:when>
  62.                                 <xsl:otherwise>
  63.                                     <img border="0" src="graphics/dot.gif"/>
  64.                                 </xsl:otherwise>
  65.                             </xsl:choose>
  66.                             <xsl:choose>
  67.                                 <xsl:when test="movie_info/@fname[. != '']">
  68.                                     <div align="center">
  69.                                         <xsl:apply-templates select="movie_info"/></div>
  70.                                 </xsl:when>
  71.                                 <xsl:otherwise>
  72.                                 <img border="0" src="graphics/dot.gif"/>
  73.                                 </xsl:otherwise>
  74.                                 </xsl:choose></div></td>
  75.                                  <td valign="top"> <div align="center"> 
  76.                                     <p><font face="Arial, Helvetica, sans-serif" size="2"><br kludge=""/>
  77.                                            <b><xsl:value-of select="title"/></b>  </font></p>
  78.                                         <p><font face="Arial, Helvetica, sans-serif" size="2">                                                                                <xsl:apply-templates select="description">
  79.                                             <!-- recursively apply this template to them -->
  80.                                             <xsl:template>
  81.                                                 <xsl:copy>
  82.                                                     <xsl:apply-templates select="@* | * | comment() | pi() | text()"/>
  83.                                                 </xsl:copy>
  84.                                             </xsl:template>
  85.                                         </xsl:apply-templates>
  86.                             </font></p>
  87.                            <br kludge=""/></div></td>
  88.                       </tr>
  89.                 </table></td>
  90.   </tr>
  91. </table>
  92. </BODY>
  93. </xsl:element>
  94. </xsl:template>
  95.  
  96.     <xsl:template match="previous">
  97.         <xsl:value-of/>
  98.         <xsl:choose>
  99.             <xsl:when match="previous[@fname != '']">
  100.                 <br kludge=""/><A><xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>View Previous Image</A>
  101.             </xsl:when>
  102.             <xsl:otherwise><br kludge=""/>View Previous Image</xsl:otherwise>
  103.         </xsl:choose>
  104.     </xsl:template>
  105.     <xsl:template match="next">
  106.         <xsl:value-of/>
  107.         <xsl:choose>
  108.             <xsl:when match="next[@fname != '']">
  109.                 <br kludge=""/><A><xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>View Next Image</A></xsl:when>
  110.             <xsl:otherwise><br kludge=""/>View Next Image</xsl:otherwise></xsl:choose></xsl:template>
  111.  
  112.     <xsl:template match="audio_info">
  113.         <A>
  114.             <xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  115.             <img border="0" src="graphics/sound.gif" width="24" height="28"/></A></xsl:template>
  116.     <xsl:template match="movie_info">
  117.         <A>
  118.             <xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  119.             <img border="0" src="graphics/movie.gif" width="25" height="28"/></A></xsl:template>
  120.  
  121. </xsl:stylesheet>
  122.