I'm using the multinode tree picker to grab and image and some text from 3 nodes. It won't pull the image with the code below, am I missing something? The XSLT to grab the image works fine when using something besides mutinode tree picker.
<ul> <!-- Loop through each of the nodeId values --> <xsl:for-eachselect="$currentPage/featuredProjects/MultiNodePicker/nodeId"> <!-- Since we only have the nodeId value, we need to get the actual content node using umbraco.library's GetXmlNodeById method --> <!-- If you prefer to use pure XPath, then used this: "$currentPage/ancestor-or-self::*[@isDoc and @level = 1]/descendant-or-self::*[@isDoc and @id = current()]" --> <xsl:variablename="node"select="umbraco.library:GetXmlNodeById(.)"/> <li> <xsl:iftest="position() mod 3 = 0"><xsl:attributename="class">last</xsl:attribute></xsl:if> <!-- Output the URL using umbraco.library's NiceUrl method --> <ahref="{umbraco.library:NiceUrl(.)}"> <xsl:variablename="mediaId"select="number(thumbnailImage)"/> <xsl:iftest="$mediaId > 0"> <xsl:variablename="mediaNode"select="umbraco.library:GetMedia($mediaId, 0)"/> <xsl:iftest="$mediaNode/umbracoFile"> <ahref="{umbraco.library:NiceUrl(@id)}"><imgsrc="{$mediaNode/umbracoFile}"alt="{$mediaNode/@nodeName}" /></a> </xsl:if> </xsl:if> </a> </li> </xsl:for-each> </ul>
MultiNode Tree picker not getting image from node
Hi,
I'm using the multinode tree picker to grab and image and some text from 3 nodes. It won't pull the image with the code below, am I missing something? The XSLT to grab the image works fine when using something besides mutinode tree picker.
Thanks
Amir
Shouldn't <xsl:iftest="$mediaId >0"> be <xsl:iftest="$mediaId > 0"> ?
is working on a reply...