[xep-support] "Filtered" Select and alternating background-color

Martin Snajdr|AMAN martin.snajdr at aman.de
Wed May 24 00:08:55 PDT 2006


Hm ok i don't know if i got it, but i'll try...
How to do this thing with the incrementing variable?
<xsl:variable name="myvar" select="$myvar+1"/>? No...???!!!

Mit freundlichen Grüßen

Martin Snajdr


-------------------------------------------------------------
Jugendtalentförderung by AMAN Media - der AMAN Cup 2006
mehr dazu unter http://www.t-a-f-i.de/
-------------------------------------------------------------

-->> mailto:Martin.Snajdr at aman.de

Martin Snajdr
AMAN Media GmbH
network & media
Dorfstrasse 2-4
85235 Unterumbach
Germany
fon: ++49-(0)8134-9100
fax: ++49-(0)8134-9110
technical support:
mailto:admin at aman.de
http://www.aman.de <http://www.aman.de/>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Diese eMail enthält vertrauliche und/oder rechtlich geschützte 
Informationen. Das unerlaubte Kopieren sowie die unbefugte 
Weitergabe/Weiterleitung dieser Mail ist nicht gestattet. Wenn Sie nicht 
der richtige Adressat sind oder diese eMail irrtümlich erhalten haben, 
informieren Sie bitte sofort den Absender und vernichten Sie diese Mail.

This e-mail may contain confidential and/or privileged information. Any 
unauthorized copying, disclosure or distribution/forwarding of the 
material in this email is strictly forbidden.

David Pirkle schrieb:
> You could try moving the body of your loop into a recursive template, and then replace the for-each with a call to the template.  That would allow you to have a variable that increments for each element that passes the filter, and you could use the modulus test on that.
> 
> -----Original Message-----
> From: owner-xep-support at renderx.com [mailto:owner-xep-support at renderx.com] On Behalf Of Martin Snajdr|AMAN
> Sent: Tuesday, May 23, 2006 1:16 AM
> To: xep-support at renderx.com
> Subject: [xep-support] "Filtered" Select and alternating background-color
> 
> Hi there,
> 
> i have a problem with a real huge table, which has to have alternating background-color in each table-row.
> As you can see in the following excerpt, i have to use a xsl:if to filter the select. But doing it this way prevents the position()-thing from working right, when the filter is active.
> 
> [..]
> <fo:table-body>
> <xsl:for-each select="article">
> 	<xsl:if test="(($filter_material='all') or ($filter_material!='all' and
> @color=$filter_material))
> 				and (($filter_knaggen='all') or ($filter_knaggen!='all' and
> contains(./attributevalue[@attid=$filter_knaggen_attrid]/value[@lang='de'],$filter_knaggen)
> ))
> 				and (($filter_nenngroesse='all') or ($filter_nenngroesse!='all' and
> contains(./attributevalue[@attid=$filter_nenngroesse_attrid]/value[@lang='de'],$filter_nenngroesse)
> ))
> 				and (($filter_eingang='all') or ($filter_eingang!='all' and
> contains(./attributevalue[@attid=$filter_eingang_attrid]/value[@lang='de'],$filter_eingang)
> ))
> 				">
> 	<fo:table-row page-break-inside="avoid">
> 	<xsl:attribute name="background-color"><xsl:if test="position() mod 2=0">rgb-icc(255,255,255,#CMYK,0,0,0,0)</xsl:if><xsl:if test="position() mod 2 != 0">rgb-icc(227, 231, 241,#CMYK,0.1,0.045,0,0.05)</xsl:if></xsl:attribute>
> [..]
> 
> 
> I tried to change the select to do the filtering, but since the filter depends on passed-in params i'm not able to do this. I tried some exslt node-set-stuff, but i didn't get to it.
> 
> Anyone any idea?
> 
> Thanks in advance!
> 
> --
> Mit freundlichen Grüßen
> 
> Martin Snajdr
> 
> 
> -------------------------------------------------------------
> Jugendtalentförderung by AMAN Media - der AMAN Cup 2006 mehr dazu unter http://www.t-a-f-i.de/
> -------------------------------------------------------------
> 
> -->> mailto:Martin.Snajdr at aman.de
> 
> Martin Snajdr
> AMAN Media GmbH
> network & media
> Dorfstrasse 2-4
> 85235 Unterumbach
> Germany
> fon: ++49-(0)8134-9100
> fax: ++49-(0)8134-9110
> technical support:
> mailto:admin at aman.de
> http://www.aman.de <http://www.aman.de/> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Diese eMail enthält vertrauliche und/oder rechtlich geschützte Informationen. Das unerlaubte Kopieren sowie die unbefugte Weitergabe/Weiterleitung dieser Mail ist nicht gestattet. Wenn Sie nicht der richtige Adressat sind oder diese eMail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail.
> 
> This e-mail may contain confidential and/or privileged information. Any unauthorized copying, disclosure or distribution/forwarding of the material in this email is strictly forbidden.
> 
> -------------------
> (*) To unsubscribe, send a message with words 'unsubscribe xep-support'
> in the body of the message to majordomo at renderx.com from the address you are subscribed from.
> (*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.html
> 
> =======
> Notice: This e-mail message, together with any attachments, contains
> information of Symyx Technologies, Inc. or any of its affiliates or
> subsidiaries that may be confidential, proprietary, copyrighted,
> privileged and/or protected work product, and is meant solely for
> the intended recipient. If you are not the intended recipient, and
> have received this message in error, please contact the sender
> immediately, permanently delete the original and any copies of this
> email and any attachments thereto.
> 
> -------------------
> (*) To unsubscribe, send a message with words 'unsubscribe xep-support'
> in the body of the message to majordomo at renderx.com from the address
> you are subscribed from.
> (*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.html

-------------------
(*) To unsubscribe, send a message with words 'unsubscribe xep-support'
in the body of the message to majordomo at renderx.com from the address
you are subscribed from.
(*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/terms-of-service.html



More information about the Xep-support mailing list