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 this code
<xsl:if test="$currentPage/ancestor-or-self::*/@id = current()/@id"> <xsl:attribute name="class">current</xsl:attribute> </xsl:if> <xsl:attribute name="href"> <xsl:choose> <xsl:when test="count(./*[@isDoc]) > 1 and string(linkToSubpage) = '1'"> <xsl:value-of select="umbraco.library:NiceUrl(./*[@isDoc]/@id)" /> </xsl:when> <xsl:otherwise> <xsl:value-of select="umbraco.library:NiceUrl(@id)" /> </xsl:otherwise> </xsl:choose> </xsl:attribute> <xsl:value-of select="@nodeName"/>
i want also to add a property (textstring) with property alias "externalUrl" so that if this field is filled up...the link goes to that address.
I must add another xslt choose I think or added some conditions in the if : if test="string(./data [@alias = 'externalUrl') != ''">.
Dunno.
Any help please.
//Sam
Ok find it.
Added a choose statement : <xsl:when test="externalUrl !=''">
is working on a reply...
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.
Continue discussion
Adding an external URL property to my site nav xslt
Hi all, I have this code
<xsl:if test="$currentPage/ancestor-or-self::*/@id = current()/@id">
<xsl:attribute name="class">current</xsl:attribute>
</xsl:if>
<xsl:attribute name="href">
<xsl:choose>
<xsl:when test="count(./*[@isDoc]) > 1 and string(linkToSubpage) = '1'">
<xsl:value-of select="umbraco.library:NiceUrl(./*[@isDoc]/@id)" />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="umbraco.library:NiceUrl(@id)" />
</xsl:otherwise>
</xsl:choose>
</xsl:attribute>
<xsl:value-of select="@nodeName"/>
i want also to add a property (textstring) with property alias "externalUrl" so that if this field is filled up...the link goes to that address.
I must add another xslt choose I think or added some conditions in the if : if test="string(./data [@alias = 'externalUrl') != ''">.
Dunno.
Any help please.
//Sam
Ok find it.
Added a choose statement : <xsl:when test="externalUrl !=''">
is working on a reply...
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.