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 Guys,
Am having some issues with umbraco.library:NiceUrl.
This is how my Content Tree looks like
- Default
-- Page 1
--- Sub Page 1
--- Sub Page 2
-- Page 2
When trying to get the URL of Page 1 From any of it Sub Pages i can this error msg
System.OverflowException: Value was either too large or too small for an Int32.
<a> <xsl:attribute name="href"> <xsl:value-of select="umbraco.library:NiceUrl($currentPage/ancestor-or-self::* [@isDoc and @level = 2]/@id)"/></xsl:attribute> <xsl:value-of select="$currentPage/ancestor-or-self::* [@isDoc and @level = 2]/@nodeName"/> </a>
/fuji
Solution here
http://our.umbraco.org/forum/developers/xslt/3102-Using-niceurl-Value-was-either-too-large-or-too-small-for-an-Int32-?p=0
Rich
Rich I still cant get the URL working.....my href is empty
Is there another solution??
This works for me. You will need to "ignore errors"
<a> <xsl:attribute name="href"> <xsl:value-of select="umbraco.library:NiceUrl($currentPage/ancestor-or-self::* [@level=2][@isDoc]/@id)"/> </xsl:attribute> <xsl:value-of select="$currentPage/ancestor-or-self::* [@level=2][@isDoc]/@nodeName"/> </a>
try this
<xsl:variable name="parentNodeLink" select="umbraco.library:NiceUrl($currentPage/ancestor-or-self::*[@isDoc and @level = 2]/@id)"/> <xsl:if test="$parentNodeLink != ''"> <a href="$parentNodeLink"> <xsl:value-of select="$currentPage/ancestor-or-self::* [@isDoc and @level = 2]/@nodeName"/> </a> </xsl:if>
Thanks Skiltz,
It working now both your solution and mine that is
I only checked the "Skip testing (ignore errors)" box.
//fuji
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Link to Level 2
Hi Guys,
Am having some issues with umbraco.library:NiceUrl.
This is how my Content Tree looks like
- Default
-- Page 1
--- Sub Page 1
--- Sub Page 2
-- Page 2
--- Sub Page 1
--- Sub Page 2
When trying to get the URL of Page 1 From any of it Sub Pages i can this error msg
System.OverflowException: Value was either too large or too small for an Int32.
/fuji
Solution here
http://our.umbraco.org/forum/developers/xslt/3102-Using-niceurl-Value-was-either-too-large-or-too-small-for-an-Int32-?p=0
Rich
Rich I still cant get the URL working.....my href is empty
Is there another solution??
This works for me. You will need to "ignore errors"
try this
Thanks Skiltz,
It working now both your solution and mine that is
I only checked the "Skip testing (ignore errors)" box.
//fuji
is working on a reply...