Ignore:
Timestamp:
2009-01-06T14:26:10+13:00 (15 years ago)
Author:
kjdon
Message:

indented the xml nicely.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • greenstone3/trunk/web/interfaces/default/transform/home.xsl

    r18304 r18316  
    1212  <xsl:output method="html"/> 
    1313 
    14     <!-- the main page layout template is here -->
     14  <!-- the main page layout template is here -->
    1515  <xsl:template match="page">
    16         <html>
    17     <head>
    18       <title>
    19     <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
    20     <xsl:call-template name="pageTitle"/><xsl:text> </xsl:text>
    21       </title>
    22       <xsl:call-template name="globalStyle"/>
    23       <xsl:call-template name="pageStyle"/>
    24     </head>
    25           <body>
    26            <div id="globalwrapper">
    27           <xsl:call-template name="response" />
    28           <xsl:call-template name="greenstoneFooter"/>
    29        </div>
    30           </body>
    31         </html>
     16    <html>
     17      <head>
     18    <title>
     19      <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
     20      <xsl:call-template name="pageTitle"/><xsl:text> </xsl:text>
     21    </title>
     22    <xsl:call-template name="globalStyle"/>
     23    <xsl:call-template name="pageStyle"/>
     24      </head>
     25      <body>
     26    <div id="globalwrapper">
     27      <xsl:call-template name="response" />
     28      <xsl:call-template name="greenstoneFooter"/>
     29    </div>
     30      </body>
     31    </html>
    3232  </xsl:template>
    3333
     
    4949  <xsl:template name="pageBanner">
    5050    <div id="banner">
    51         <p>
    52             <img src="interfaces/default/images/gsdlhead.gif"><xsl:attribute name="alt"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/></xsl:attribute>
    53             </img>
    54     </p>
     51      <p>
     52    <img src="interfaces/default/images/gsdlhead.gif"><xsl:attribute name="alt"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/></xsl:attribute>
     53    </img>
     54      </p>
    5555    </div>
    5656    <div id="content">
    57     <xsl:call-template name="dividerBar">
    58             <xsl:with-param name="text" select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/>
    59         </xsl:call-template>   
    60       </div>
     57      <xsl:call-template name="dividerBar">
     58    <xsl:with-param name="text" select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/>
     59      </xsl:call-template> 
     60    </div>
    6161  </xsl:template>
    6262
    6363  <xsl:template match="collectionList">
    64    <ul id="collectionlist">
    65     <xsl:for-each select="collection">
    66       <li>
    67      
    68            <xsl:choose>
    69               <xsl:when test="displayItem[@name='icon']">
     64    <ul id="collectionlist">
     65      <xsl:for-each select="collection">
     66    <li>
     67     
     68      <xsl:choose>
     69        <xsl:when test="displayItem[@name='icon']">
    7070              <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
    7171                <img>
    72                <xsl:attribute name="src">
    73                  <xsl:value-of select="metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="displayItem[@name='icon']"/>
    74                </xsl:attribute>
    75                <xsl:attribute name="alt">
    76                     <xsl:value-of select="displayItem[@name='name']"/>
    77                </xsl:attribute>
    78              </img>
    79                </a> 
    80           </xsl:when>
    81               <xsl:otherwise>
    82                <a class="noimage" href="{$library_name}?a=p&amp;sa=about&amp;c={@name}"> 
    83                  <xsl:value-of select="displayItem[@name='name']"/>
    84                </a>
    85               </xsl:otherwise>
    86            </xsl:choose>         
    87      
    88        </li>
    89     </xsl:for-each>
    90    </ul>
     72          <xsl:attribute name="src">
     73            <xsl:value-of select="metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="displayItem[@name='icon']"/>
     74          </xsl:attribute>
     75          <xsl:attribute name="alt">
     76            <xsl:value-of select="displayItem[@name='name']"/>
     77          </xsl:attribute>
     78        </img>
     79          </a> 
     80        </xsl:when>
     81        <xsl:otherwise>
     82          <a class="noimage" href="{$library_name}?a=p&amp;sa=about&amp;c={@name}"> 
     83        <xsl:value-of select="displayItem[@name='name']"/>
     84          </a>
     85        </xsl:otherwise>
     86      </xsl:choose>         
     87      
     88    </li>
     89      </xsl:for-each>
     90    </ul>
    9191  </xsl:template>
    9292 
     
    113113    <xsl:call-template name="dividerBar"/>
    114114    <ul id="servicelist">
    115     <xsl:for-each select="service[@type='query']">
    116       <li><a href="{$library_name}?a=q&amp;rt=d&amp;s={@name}"><xsl:value-of select="displayItem[@name='name']"/></a><xsl:value-of select="displayItem[@name='description']"/></li>
     115      <xsl:for-each select="service[@type='query']">
     116    <li><a href="{$library_name}?a=q&amp;rt=d&amp;s={@name}"><xsl:value-of select="displayItem[@name='name']"/></a><xsl:value-of select="displayItem[@name='description']"/></li>
    117117      </xsl:for-each>
    118118      <!--uncomment to display an authentication link-->
    119        <!--<xsl:for-each select="service[@type='authen']">
     119      <!--<xsl:for-each select="service[@type='authen']">
    120120      <li><a href="{$library_name}?a=g&amp;rt=r&amp;sa=authen&amp;s={@name}&amp;s1.aup=Login&amp;s1.un=&amp;s1.asn="><xsl:value-of select="displayItem[@name='name']"/></a><xsl:value-of select="displayItem[@name='description']"/></li>      </xsl:for-each>-->
    121121      <!--uncomment to display a library interface link-->
    122122      <!--<li><a href="{$library_name}?a=p&amp;sa=gli4gs3"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.librarian_interface')"/></a></li>-->
    123123    </ul>
    124     </xsl:template>
     124  </xsl:template>
    125125</xsl:stylesheet> 
    126126
Note: See TracChangeset for help on using the changeset viewer.