home *** CD-ROM | disk | FTP | other *** search
/ Chip 2003 May / CHIP_CD_2003-05.iso / software / jpspa / files / ppa400ev.exe / Data1.cab / single.xsl14 < prev    next >
Encoding:
Extensible Markup Language  |  2003-02-17  |  6.8 KB  |  149 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.     <xsl:template match="/">
  9.         <HTML>
  10.             <xsl:apply-templates/>
  11.         </HTML>
  12.     </xsl:template>
  13.     <xsl:template match="photos">
  14.         <xsl:apply-templates/>
  15.     </xsl:template>
  16.     <xsl:template match="album">
  17.         <xsl:apply-templates select="imagelist"/>
  18.     </xsl:template>
  19.     <xsl:template match="imagelist">
  20.         <xsl:apply-templates select="imageinfo"/>
  21.     </xsl:template>
  22.     <xsl:template match="imageinfo">
  23.         <xsl:element name="ixfile">
  24.             <xsl:attribute name="fname"><xsl:value-of select="html_info/@fname"/></xsl:attribute>
  25.             <head>
  26.         <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
  27.         <meta name="copyright" content="Copyright (C) 1995-2003 Jasc Software, Inc. and its licensors. All rights reserved."/>
  28.  
  29.                 <SCRIPT>
  30.                     <xsl:comment>
  31.  
  32.  
  33.  
  34.   function MM_swapImgRestore() { //v3.0
  35.   <![CDATA[var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
  36. }
  37.  
  38. function MM_preloadImages() { //v3.0
  39.   var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
  40.     var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
  41.     if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
  42. }
  43.  
  44. function MM_findObj(n, d) { //v3.0
  45.   var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
  46.     d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  47.   if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  48.   for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
  49. }
  50.  
  51. function MM_swapImage() { //v3.0
  52.   var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
  53.    if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
  54. }
  55. ]]>//</xsl:comment>
  56.                 </SCRIPT>
  57.             </head>
  58.             <body bgcolor="#FFFFFF" text="#990000" onLoad="MM_preloadImages('buttons/role_over1_over.gif','buttons/role_over2_over.gif')">
  59. <table border="0" cellspacing="5" cellpadding="5" align="center" height="480">
  60.   <tr valign="top"> 
  61.     <td><table border="0" cellspacing="0" cellpadding="0" height="480">
  62.         <tr> 
  63.           <td height="33"><table border="0" cellspacing="0" cellpadding="0" align="center">
  64.               <tr> 
  65.                 <td><xsl:apply-templates select="previous"/></td>
  66.                 <td width="200"><div align="center"><font face="Arial, Helvetica, sans-serif" size="4" ><xsl:value-of select="title"/></font></div></td>
  67.                 <td><xsl:apply-templates select="next"/></td>
  68.               </tr>
  69.             </table><br kludge=""/></td>
  70.         </tr>
  71.         <tr valign="top"> 
  72.           <td height="367"><div align="center"><table border="0" cellspacing="0" cellpadding="0">
  73.                 <tr> 
  74.                   <td height="367" width="80"><img src="graphics/rightgradient.jpg" width="80" height="367"/></td>
  75.                   <td height="367"><table border="2" cellspacing="0" cellpadding="0" bordercolor="#990000" bgcolor="#990000">
  76.                       <tr> 
  77.                         <td><IMG border="0"><xsl:attribute name="src"><xsl:value-of select="@fname"/></xsl:attribute><xsl:attribute name="width"><xsl:value-of select="imagesize/@width"/></xsl:attribute>
  78.                         <xsl:attribute name="height"><xsl:value-of select="imagesize/@height"/></xsl:attribute>
  79.                         <xsl:attribute name="alt"><xsl:value-of select="title"/></xsl:attribute></IMG></td>
  80.                       </tr>
  81.                     </table></td>
  82.                   <td height="367" width="80"><img src="graphics/leftgradient.jpg" width="80" height="367"/></td>
  83.                 </tr></table></div></td>
  84.         </tr>
  85.         <tr valign="top"> 
  86.           <td height="50"><div align="center"><br kludge=""/>
  87.               <xsl:choose>
  88.                                                             <xsl:when test="audio_info/@fname[. != '']">
  89.                                                                 <div align="center"><xsl:apply-templates select="audio_info"/></div>
  90.                                                             </xsl:when>
  91.                                                             <xsl:otherwise>
  92.                                                                 <div align="center"><img border="0" src="graphics/transparenth120.gif" width="1" height="1"/></div>
  93.                                                             </xsl:otherwise>
  94.                                                         </xsl:choose><xsl:choose>
  95.                                                     <xsl:when test="movie_info/@fname[. != '']">
  96.                                                         <div align="center"><xsl:apply-templates select="movie_info"/></div>
  97.                                                     </xsl:when>
  98.                                                     <xsl:otherwise>
  99.                                                         <div align="center"><img border="0" src="graphics/transparenth120.gif" width="1" height="1"/></div>
  100.                                                     </xsl:otherwise>
  101.                                                 </xsl:choose><font face="Arial, Helvetica, sans-serif" size="2" ><xsl:apply-templates select="description">
  102.                                             <!-- recursively apply this template to them -->
  103.                                             <xsl:template>
  104.                                                 <xsl:copy>
  105.                                                     <xsl:apply-templates select="@* | * | comment() | pi() | text()"/>
  106.                                                 </xsl:copy>
  107.                                             </xsl:template>
  108.                                         </xsl:apply-templates></font></div></td>
  109.         </tr></table></td>
  110.   </tr></table>
  111. </body>
  112.         </xsl:element>
  113.     </xsl:template>
  114.     <xsl:template match="audio_info">
  115.         <xsl:if match="audio_info[@fname != '']">
  116.             <A><xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  117.                 <img border="0" src="graphics/sound.gif"/></A>
  118.         </xsl:if>
  119.     </xsl:template>
  120.     <xsl:template match="movie_info">
  121.         <A><xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  122.             <img border="0" src="graphics/movie.gif" width="24" height="28"/></A>
  123.     </xsl:template>    <xsl:template match="previous">
  124.         <xsl:value-of/>
  125.         <xsl:choose>
  126.             <xsl:when match="previous[@fname != '']">
  127.                 <A onMouseOver="MM_swapImage('Image1','','buttons/role_over1_over.gif',1)" onMouseOut="MM_swapImgRestore()">
  128.                     <xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  129.                     <img src="buttons/role_over1.gif" name="Image1" width="131" height="33" border="0"/></A>
  130.             </xsl:when>
  131.             <xsl:otherwise>
  132.                 <img src="buttons/role_over1.gif" width="131" height="33" border="0"/>
  133.             </xsl:otherwise>
  134.         </xsl:choose>
  135.     </xsl:template>
  136.     <xsl:template match="next">
  137.         <xsl:value-of/>
  138.         <xsl:choose>
  139.             <xsl:when match="next[@fname != '']">
  140.                 <A onMouseOver="MM_swapImage('Image2','','buttons/role_over2_over.gif',1)" onMouseOut="MM_swapImgRestore()">                    <xsl:attribute name="href"><xsl:value-of select="@fname"/></xsl:attribute>
  141.                     <img src="buttons/role_over2.gif" name="Image2" width="131" height="33" border="0"/></A>
  142.             </xsl:when>
  143.             <xsl:otherwise>
  144.                 <img src="buttons/role_over2.gif" width="131" height="33" border="0"/>
  145.             </xsl:otherwise>
  146.         </xsl:choose>
  147.     </xsl:template>
  148. </xsl:stylesheet>
  149.