Sitecore FYI post

14. August 2016 15:29 by Mark Servais in Sitecore  //  Tags:   //   Comments (0)

Just a really quick note on something I encountered this past week.....

I was working with a LinkField in Sitecore and I needed to retreive the Url. Obviously the Url property on the link field is available but doesn’t populate for internal links. So to determine when to use the field Url or process the internal link I was using the IsInternal property. Well I found out that this property isn’t always accurate. Confirmed by Mike Reynolds, another Sitecore MVP and enthusiast, when the LinkType is null or blank, it defaults to “internal”. This means if you clear out your LinkField, the IsInternal property will return true.

 

A Sitecore bug has been logged and the public reference number 120621 can be used to track status. More information about public reference numbers can be found here.

 

For the time being until the fix is put in a future update to Sitecore, check the LinkField TargetID property of IsGlobalNullId to determine if the LinkField is truly referencing a Sitecore item and thus really an internal link.


Calendar

<<  October 2019  >>
MonTueWedThuFriSatSun
30123456
78910111213
14151617181920
21222324252627
28293031123
45678910

View posts in large calendar

Month List