Output of a related links datatype is an xml snippet, so you don't see anything unless you look at the source of the page, then you'll notice a small xml snippet representing all related links.
Also, there's a template available from the template dropdown when creating a new xslt ('Related Links'), and that one should give you a start on how to show the related links on your site.
Related Link issue
Hi guys,
I am trying to display a related link on a page but from a macro due to multiple languages.
The whole site works but I cant get anything to display for the link. do I need to wrap it in a HTML anchor?
This is my link in the XSLT:
<xsl:value-of select="data [@alias = concat ('aboutusLink',$flang)]"/>
Thanks
Roger
Simple and perhaps obvious, but have you checked to make sure your concat is generating what you expect (correct field name)?
THanks,
Nik
Hi Roger,
Output of a related links datatype is an xml snippet, so you don't see anything unless you look at the source of the page, then you'll notice a small xml snippet representing all related links.
So, you'll need to iterate your links in order to display the data.
Also, there's a template available from the template dropdown when creating a new xslt ('Related Links'), and that one should give you a start on how to show the related links on your site.
Hope this helps.
Regards,
/Dirk
Hi Guys,
I got it working with Dirks solution but I have to add $currentPage in order to get it to display.
<xsl:for-each select="$currentPage/data[@alias = concat('aboutusLink',$flang)]/links/link">
Many thanks!
Roger
is working on a reply...