cnibspteam
asked on
map out SharePoint column as link through XSLT
I am creating an XSLT style which, as one of the requirements, pulls a url from a column, and displays the link with the anchor tag around it.
I created a custom column called "webpage", and although I am able to get the link to render, I don't know how to structure the XSLT to make the link work.
Here is what I have so far:
The other weird thing is that even though I can output the name it renders twice with a comma separating them. I'm not sure why.
Thanks for the assistance!
I created a custom column called "webpage", and although I am able to get the link to render, I don't know how to structure the XSLT to make the link work.
Here is what I have so far:
<xsl:template name="Aspiro-ResourceProfiles" match="Row[@Style='Aspiro-ResourceProfiles']" mode="itemstyle">
<div class="ResourceProfile">
<h2><xsl:value-of select="@Title" disable-output-escaping="yes"/></h2>
<xsl:if test="@Byline !=''"><!-- conditional Byline if NOT empty -->
<p><xsl:value-of select="@Byline" disable-output-escaping="yes" /></p>
</xsl:if>
<p><a href=""><xsl:value-of select="@WebPage" disable-output-escaping="yes" /></a></p>
<p><xsl:value-of select="@Description" disable-output-escaping="yes" /></p>
<p><strong>Keywords: </strong><xsl:value-of select="@Keywords" disable-output-escaping="yes"/></p>
</div>
</xsl:template>
The other weird thing is that even though I can output the name it renders twice with a comma separating them. I'm not sure why.
Thanks for the assistance!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
welcome
ASKER
It seems that the duplication is caused by the type of column I used which uses the URL and Description. If you don't input a description it duplicated the URL in that field.
I'm just going to have to use a different column instead. Thanks for the help!