Changeset 947

Show
Ignore:
Timestamp:
09/28/07 17:59:19 (10 months ago)
Author:
mikey
Message:

fixed tabs
remove needless whitespace from stub:argument
(finally fixes ticket #81)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/examples/pages/txt/main_index.xml

    r915 r947  
    2929      <!-- test a link --> 
    3030      <stub:link page="test"> 
    31                <stub:argument name="argument">wert</stub:argument> 
    32                <stub:argument name="argument2">noch_ein_wert</stub:argument> 
    33                Test 
    34            </stub:link> 
     31        <stub:argument name="argument">wert</stub:argument> 
     32        <stub:argument name="argument2">noch_ein_wert</stub:argument> 
     33        Test 
     34      </stub:link> 
    3535      <!-- This is an include from a different file --> 
    3636      <stub:include part="disclaimer" href="include/parts.xml"/> 
  • trunk/src/main/resources/xsl/stub.xsl

    r915 r947  
    77    exclude-result-prefixes="php xi ixsl stub"> 
    88 
     9  <xsl:strip-space elements="stub:link" /> 
     10   
    911  <xsl:template match="stub:document"> 
    1012    <ixsl:stylesheet version="1.0" exclude-result-prefixes="ixsl"> 
     
    1517        <xsl:copy-of select="@doctype-system" /> 
    1618      </ixsl:output> 
    17            <ixsl:variable name="page" select="/document/@page" /> 
    18            <ixsl:variable name="__sessid" select="/document/session/id" /> 
    19            <ixsl:variable name="__sessname" select="/document/session/name" /> 
     19      <ixsl:variable name="page" select="/document/@page" /> 
     20      <ixsl:variable name="__sessid" select="/document/session/id" /> 
     21      <ixsl:variable name="__sessname" select="/document/session/name" /> 
    2022      <ixsl:template match="/"> 
    2123        <xsl:apply-templates select="node()"/> 
     
    4951  <xsl:template match="stub:link"> 
    5052    <a> 
    51       <ixsl:attribute name="href"> 
     53    <ixsl:attribute name="href"> 
     54      <xsl:choose> 
     55        <xsl:when test="@processor"> 
     56          <xsl:value-of select="@processor"/> 
     57        </xsl:when> 
     58        <xsl:otherwise> 
     59          <xsl:text>xml</xsl:text> 
     60        </xsl:otherwise> 
     61      </xsl:choose> 
     62      <xsl:text>/</xsl:text> 
     63      <xsl:value-of select="@page"/> 
     64      <xsl:text>;</xsl:text> 
     65      <ixsl:value-of select="$__sessname"/> 
     66      <xsl:text>=</xsl:text> 
     67      <ixsl:value-of select="$__sessid"/> 
     68      <xsl:for-each select="./stub:argument"> 
    5269        <xsl:choose> 
    53           <xsl:when test="@processor"> 
    54             <xsl:value-of select="@processor"/
     70          <xsl:when test="position() = 1"> 
     71            <xsl:text>?</xsl:text
    5572          </xsl:when> 
    5673          <xsl:otherwise> 
    57            <xsl:text>xml</xsl:text> 
     74            <xsl:text>&amp;</xsl:text> 
    5875          </xsl:otherwise> 
    5976        </xsl:choose> 
    60                 <xsl:text>/</xsl:text> 
    61         <xsl:value-of select="@page"/> 
    62                 <xsl:text>;</xsl:text> 
    63                 <ixsl:value-of select="$__sessname"/> 
    64                 <xsl:text>=</xsl:text> 
    65                 <ixsl:value-of select="$__sessid"/> 
    66                 <xsl:for-each select="./stub:argument"> 
    67                     <xsl:choose> 
    68                         <xsl:when test="position() = 1"> 
    69                             <xsl:text>?</xsl:text> 
    70                         </xsl:when> 
    71                         <xsl:otherwise> 
    72                             <xsl:text>&amp;</xsl:text> 
    73                         </xsl:otherwise> 
    74                     </xsl:choose> 
    75                     <xsl:value-of select="@name"/> 
    76                     <xsl:text>=</xsl:text> 
    77                     <xsl:value-of select="."/> 
    78                 </xsl:for-each> 
    79       </ixsl:attribute> 
    80       <xsl:apply-templates/> 
     77        <xsl:value-of select="@name"/> 
     78        <xsl:text>=</xsl:text> 
     79        <xsl:value-of select="."/> 
     80      </xsl:for-each> 
     81    </ixsl:attribute> 
     82    <xsl:apply-templates/> 
    8183    </a> 
    8284  </xsl:template>