Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Patrick 23 posts 83 karma points
    Mar 05, 2012 @ 20:36
    Patrick
    0

    xslt within class

    I have a list of nodes, each of the nodes I want to give a class with the position of the node.

    To get the position I am using: <xsl:value-of select="position()"/>

    How do I insert this value within my class, which is <li class="navigatie">

    My target is to generate a list like:

    <li class="navigatie1"> ....
    <
    li class="navigatie2"> ....
    <li class="navigatie3"> ....

    How to achieve this?

    Greetings, Patrick

  • Lee Kelleher 4026 posts 15836 karma points MVP 13x admin c-trib
    Mar 05, 2012 @ 21:12
    Lee Kelleher
    2

    Hi Patrick,

    You can use the following syntax to output the position() inline...

    <li class="navigatie{position()}">

    Cheers, Lee.

  • Patrick 23 posts 83 karma points
    Mar 06, 2012 @ 20:47
    Patrick
    0

    Thanks!

Please Sign in or register to post replies

Write your reply to:

Draft