Copied to clipboard

Flag this post as spam?

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


  • Ernst Utvik 123 posts 235 karma points
    Sep 09, 2010 @ 14:03
    Ernst Utvik
    0

    Get member property problem

    After upgrading to 4.5.2 im having some problems upgrading to new xslt schema. The converter by Tommy Poulsen has helped me a lot but im stuck on the following:

    Old schema:
    <xsl:value-of select="umbraco.library:GetMember($mId)/data [@alias = 'memberAvatar']"/>

    New schema:
    <xsl:value-of select="umbraco.library:GetMember($mId)/memberAvatar"/>


    Old one works in 4.0.x but new one wont work in 4.5.x.

    umbraco.library:GetMember($mId) successfully spits out all member properties but i cant retrieve single properties.

  • Sascha Wolter 615 posts 1101 karma points
    Sep 09, 2010 @ 14:58
    Sascha Wolter
    0

    Hi Ernst,

    don't know directly the answer to that, but here is a way that will probably lead to the solution. Can you please add the following to your xslt and have a look at the output:

    <textarea style="width: 300px; height: 200px;">
    <xsl:copy-of select="umbraco.library:GetMember($mId)" />
    </textarea>

    That should give you an idea of the xml that gets returned, which should allow you to amend your xpath expression accordingly.

    Sascha

  • Ernst Utvik 123 posts 235 karma points
    Sep 10, 2010 @ 12:21
    Ernst Utvik
    0

    Hi Sascha,

    Thnx for the reply. Xml output seemed ok to me, but after fiddeling with the problem for a while longer I found a solution. Posting it here for future reference:

    My original code that didnt work:
    <xsl:value-of select="umbraco.library:GetMember($mId)/memberAvatar"/>

    Working code:
    <xsl:value-of select="umbraco.library:GetMember($mId)/*/memberAvatar"/>

Please Sign in or register to post replies

Write your reply to:

Draft