[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Problem With Different Colors for Alternate Rows
"Schwartz, Rechell R, ALCAS" <rrschwartz@xxxxxxx> wrote: > Jeorg, > > Thank you. Mode seems to be working ok, except for one thing -- in my > real XSLT (which is more complicated than the sample below), for certain > data elements (e.g., side dish) I search for multiple occurences of the > element and I concatenate them with commas as below. This is causing > confusion in the assessment of the position() function. It seems to > think I am looking for the position of the row, when I am really looking > for the position of this particular side dish. This confusion is causing > each side dish to print out on a new line instead of on a single line > with a comma-separated list. Is there any way to test if this side dish > is first or last w/o using the position() function (thus avoiding this > type of confusion)? Hi Jeorg. If what you want is to know if this side dish is the first in a row, you only need to tes if there is another one before, something like this: <xsl:if test="not(preceding-sibling::sidedish)"> <!-- do whatever you wnat to do--> </xsl:if> -- +-------------------------------------+ | This email was sent using V-Webmail | | http://www.v-webmail.co.uk/ | +-------------------------------------+ -- +-------------------------------------+ | This email was sent using V-Webmail | | http://www.v-webmail.co.uk/ | +-------------------------------------+ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|