Subject: RE: for-each sort of thing in {} ? From: "Carole E. Mah" <carole@xxxxxxxxxxxxxxxxxx> Date: Thu, 8 Jun 2000 16:50:50 -0400 (EDT) |
On Thu, 8 Jun 2000, Ben Robb wrote: > <xsl:template match="foo"> > <xsl:variable name="qstring"> > <xsl:for-each select="bar"> > <xsl:if test="postition() != 1"> > & > </xsl:if> > id<xsl:value-of select="position()"/>=<xsl:value-of > select="@id"/> > </xsl:for-each> > </xsl:variable> > </xsl:template> Ben, Thanks very, very much. Duh, of course a variable is the solution. However, one has to change the content of the XSL:FOR-EACH element to: <xsl:if test="position() != 1">&</xsl:if>id<xsl:value-of select="position()"/>=<xsl:value-of select="@id"/> so that the whitespace does not become part of the element. - - - - - - - - - - - - - - - - - - - - - - - - - - - Carole E. Mah Carole_Mah@xxxxxxxxx Senior Programmer/Analyst Brown University Scholarly Technology Group phn 401-863-2669 fax 401-863-9313 http://www.stg.brown.edu/ personal: http://www.stg.brown.edu/staff/carole.html XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
XPointer support in document() ?, Dave Carlson | Thread | Xpath and copy-of, Carlos Sanchez |
Re: multilanguage support easily or, Mike Brown | Date | Re: Streaming XML using XSLT [ was , Jeff Greif |
Month |