Copied to clipboard

Flag this post as spam?

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


  • Kurisotofa 27 posts 75 karma points
    Apr 30, 2009 @ 17:13
    Kurisotofa
    0

    Retrieve IMG SRC from a Page's childNodes

    My Tree structure :

    Root
    - en (docFolder)
    -- Homepage (docHomePage)
    --- Button1 (docButton)
    --- Button2 (docButton)
    --- Button3 (docButton)
    --- Button4 (docButton)
    -- Other Pages (docTextPage)


    Properties of Document Type "docButton" :
    - prpButtonBackground : Media Picker
    - prpButtonLink : Content Picker
    - prpButtonText : text box

    Now I wanted to write an XSLT I invoke in temHomePage (template used for document type "docHomePage"), that would write the appropiate IMG-tag for each "docButton"-childNode in "HomePage".

    What I have so far...

    [code]

    ]>

    version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:msxml="urn:schemas-microsoft-com:xslt"
    xmlns:umbraco.library="urn:umbraco.library" xmlns:Exslt.ExsltCommon="urn:Exslt.ExsltCommon" xmlns:Exslt.ExsltDatesAndTimes="urn:Exslt.ExsltDatesAndTimes" xmlns:Exslt.ExsltMath="urn:Exslt.ExsltMath" xmlns:Exslt.ExsltRegularExpressions="urn:Exslt.ExsltRegularExpressions" xmlns:Exslt.ExsltStrings="urn:Exslt.ExsltStrings" xmlns:Exslt.ExsltSets="urn:Exslt.ExsltSets"
    exclude-result-prefixes="msxml umbraco.library Exslt.ExsltCommon Exslt.ExsltDatesAndTimes Exslt.ExsltMath Exslt.ExsltRegularExpressions Exslt.ExsltStrings Exslt.ExsltSets ">













    [/code]

    Anyone can give me a clue?

  • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
    Apr 30, 2009 @ 21:12
    Dirk De Grave
    0

    Hi,

    [code]
    [/code]
    Aren't you suppose to use $parent/data... instead of ./data?

    Cheers,
    /Dirk

  • Kurisotofa 27 posts 75 karma points
    May 01, 2009 @ 09:13
    Kurisotofa
    0

    Found the solution myself somewhere in this forum :

    [code]

    [/code]

    Instead of calling a (sub-)template, I simply had to include a -check to avoid the compiling errors I had before.

    To access the child's properties :

    1.

Please Sign in or register to post replies

Write your reply to:

Draft