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 / mail2document.xsl < prev    next >
Encoding:
Extensible Markup Language  |  2004-07-12  |  2.3 KB  |  75 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. <xsl:stylesheet version="1.0" 
  18.   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  19.   xmlns:page="http://apache.org/cocoon/paginate/1.0"
  20.   xmlns:mail="http://apache.org/cocoon/mail/1.0"
  21.   exclude-result-prefixes="xsl page mail"
  22. >
  23.  
  24. <xsl:template match="document">
  25.   <document>
  26.     <body>
  27.       <xsl:apply-templates select="body/*"/>
  28.     </body>
  29.   </document>
  30. </xsl:template>
  31.  
  32. <xsl:template match="body">
  33.   <xsl:apply-templates/>
  34. </xsl:template>
  35.  
  36. <xsl:template match="mail:mail">
  37.   <xsl:apply-templates/>
  38. </xsl:template>
  39.  
  40. <xsl:template match="mail:folder">
  41.   <div class="list" style="width: 90%;">
  42.     <div class="row">
  43.       <span class="left">Name</span> <span class="right"> <xsl:value-of select="@name"/> </span>
  44.     </div>
  45.     <div class="row">
  46.       <span class="left">Total Messages</span> <span class="right"> <xsl:value-of select="@total-messages"/> </span>
  47.     </div>
  48.     <div class="row">
  49.       <span class="left">New Messages</span> <span class="right"> <xsl:value-of select="@new-messages"/> </span>
  50.     </div>
  51.     <div class="row">
  52.       <span class="left">Deleted Messages</span> <span class="right"> <xsl:value-of select="@deleted-messages"/> </span>
  53.     </div>
  54.     <div class="row">
  55.       <span class="left">Unread Message</span> <span class="right"> <xsl:value-of select="@unread-messages"/></span>
  56.     </div>
  57.     <div class="spacer"/>
  58.     <ul style="padding: 5px; ">
  59.       <li>Name <xsl:value-of select="@name"/></li>
  60.       <li>Fullname <xsl:value-of select="@full-name"/></li>
  61.       <li>URLname <xsl:value-of select="@url-name"/></li>
  62.     </ul>
  63.     <div class="spacer"/>
  64.   </div>
  65. </xsl:template>
  66.  
  67. <xsl:template match="@*|*|text()" priority="-1">
  68.   <xsl:copy>
  69.     <xsl:apply-templates select="@*|*|text()"/>
  70.   </xsl:copy>
  71. </xsl:template>
  72.  
  73. </xsl:stylesheet>
  74.  
  75.