Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi all,
I have a property called <xsl:value-of select="slideDescription"/>
if this data is null in the node factory i wont display the read url link to
that document <a href="{umbraco.library:NiceUrl(@id)}"> <xsl:value-of select="umbraco.library:GetDictionaryItem('readmore')"/></a>
any code samples in xslt will be very useful
thank you
Hi Max,
you could use
<xsl:if test="string(slideDescription) != ''"> <a href="{umbraco.library:NiceUrl(@id)}">...</a></xsl:if>
Cheers,
/Dirk
Hi Max
I would use the normalize-space() function to check for any leading or trailing white-space.You can also use it to check for any input in an node, when doing like this.
<xsl:template match="/"> <xsl:apply-templates select="$currentPage" /> </xsl:template> <xsl:template match="CurrentDocumentType"> <xsl:apply-templates select="slideDescription[normalize-space()]" /> </xsl:template> <xsl:template match="slideDescription"> <a href="{umbraco.library:NiceUrl(ancestor::*[@isDoc]/@id)}"> <xsl:value-of select="umbraco.library:GetDictionaryItem('readmore')"/> </a> </xsl:template>
Remember to change 'CurrentDocumentType' the nodename of current page.
thanks it was very useful :) cheers to you guys
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
display based on property value in xslt
Hi all,
I have a property called <xsl:value-of select="slideDescription"/>
if this data is null in the node factory i wont display the read url link to
that document <a href="{umbraco.library:NiceUrl(@id)}">
<xsl:value-of select="umbraco.library:GetDictionaryItem('readmore')"/></a>
any code samples in xslt will be very useful
thank you
Hi Max,
you could use
Cheers,
/Dirk
Hi Max
I would use the normalize-space() function to check for any leading or trailing white-space.
You can also use it to check for any input in an node, when doing like this.
Remember to change 'CurrentDocumentType' the nodename of current page.
thanks it was very useful :) cheers to you guys
is working on a reply...