Copied to clipboard

Flag this post as spam?

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


  • Lee 1123 posts 3059 karma points
    Jul 17, 2009 @ 13:23
    Lee
    0

    Is My Syntax Right?

    I'm trying to grab the value of a property on a document by passing in just the nodeID and property alias (I have then used a macro property so I can easily switch the node id)

    <xsl:value-of select="$currentPage/ancestor-or-self::node/descendant-or-self::node/node [@id = '[#TheNodeID]']/@StudioImage "/>

    Unfortunately I am getting nothing back, but getting no error - So I'm just not sure if I have the right syntax?

  • Ron Brouwer 273 posts 768 karma points
    Jul 17, 2009 @ 13:25
    Ron Brouwer
    1

    just use:

     select="//node[@id=$yourid]"

  • Peter Dijksterhuis 1442 posts 1722 karma points
    Jul 17, 2009 @ 13:28
    Peter Dijksterhuis
    100

    You could try this:

    <xsl:value-of select="umbraco.library:GetXmlNodeById(1243)/data [@alias = 'StudioImage']"/>

  • Lee 1123 posts 3059 karma points
    Jul 17, 2009 @ 13:39
    Lee
    0

    Thanks for the help :)

    Really need to start looking in the Umbraco.Library before posting... DOH!

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies