]> granicus.if.org Git - docbook-dsssl/commitdiff
Fixed problem of PI name suffix being matched instead of whole name.
authorBob Stayton <bobs@sagehill.net>
Wed, 11 Aug 2004 22:43:56 +0000 (22:43 +0000)
committerBob Stayton <bobs@sagehill.net>
Wed, 11 Aug 2004 22:43:56 +0000 (22:43 +0000)
xsl/lib/lib.xweb

index 8770f1e4a535212fd991b92367cc0b3979884662..b461db45c00aa3ea905a0808410c4d531a8849ad 100644 (file)
@@ -442,9 +442,12 @@ for example), the template may silently return erroneous results.</para>
       <xsl:variable name="pi">
         <xsl:value-of select="$pis[$count]"/>
       </xsl:variable>
+      <xsl:variable name="pivalue">
+        <xsl:value-of select="concat(' ', normalize-space($pi))"/>
+      </xsl:variable>
       <xsl:choose>
-        <xsl:when test="contains($pi,concat(' ', $attribute, '='))">
-          <xsl:variable name="rest" select="substring-after($pi,concat(' ', $attribute,'='))"/>
+        <xsl:when test="contains($pivalue,concat(' ', $attribute, '='))">
+          <xsl:variable name="rest" select="substring-after($pivalue,concat(' ', $attribute,'='))"/>
           <xsl:variable name="quote" select="substring($rest,1,1)"/>
           <xsl:value-of select="substring-before(substring($rest,2),$quote)"/>
         </xsl:when>