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 an old xslt code that i've written some days back now - I want to convert it to razor - and need some help on this:
Heres the code:
<xsl:for-each select="$currentPage">
<div class="fb-like-cn">
<a>
<xsl:attribute name="href">
http://www.facebook.com/sharer.php?s=100&p[title]=<xsl:value-of select="newsTitle"/>&p[url]=http://www.fireworks.mu<xsl:value-of select="umbraco.library:NiceUrl(@id)"/>&p[images][0]=&p[summary]=<xsl:value-of select="newsDescription"/>
</xsl:attribute>
<xsl:attribute name="target">blank</xsl:attribute>
<img src="/images/facebookshare.jpg" width="60" height="18" alt="Facebook share" border="0" />
</a>
</div>
</xsl:for-each>
It takes custom umbraco field on a news page and share on facebook - also i am gettin problem to retrieve an uploaded image with the xslt code - can it be resolved in razor?
Thks.
Hi Sam
What version of Umbraco are you using? Just asking because it matters in regards to how the Razor should be written :)
/Jan
Am on umbraco v 4.11.8
In that case it's best to use Partial View Macro Files because they can be added as macro's on your masterpage templates (assuming you're still using webforms). Read this for more info: http://our.umbraco.org/forum/developers/razor/44664-Confused-over-when-DynamicNodeList-is-returned?p=0#comment160691
Some documentation: http://our.umbraco.org/documentation/Reference/Mvc/querying
Jeroen
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Converting an old XSLT code to RAzor
Hi all
I have an old xslt code that i've written some days back now - I want to convert it to razor - and need some help on this:
Heres the code:
<xsl:for-each select="$currentPage">
<div class="fb-like-cn">
<a>
<xsl:attribute name="href">
http://www.facebook.com/sharer.php?s=100&p[title]=<xsl:value-of select="newsTitle"/>&p[url]=http://www.fireworks.mu<xsl:value-of select="umbraco.library:NiceUrl(@id)"/>&p[images][0]=&p[summary]=<xsl:value-of select="newsDescription"/>
</xsl:attribute>
<xsl:attribute name="target">blank</xsl:attribute>
<img src="/images/facebookshare.jpg" width="60" height="18" alt="Facebook share" border="0" />
</a>
</div>
</xsl:for-each>
It takes custom umbraco field on a news page and share on facebook - also i am gettin problem to retrieve an uploaded image with the xslt code - can it be resolved in razor?
Thks.
Hi Sam
What version of Umbraco are you using? Just asking because it matters in regards to how the Razor should be written :)
/Jan
Am on umbraco v 4.11.8
In that case it's best to use Partial View Macro Files because they can be added as macro's on your masterpage templates (assuming you're still using webforms). Read this for more info: http://our.umbraco.org/forum/developers/razor/44664-Confused-over-when-DynamicNodeList-is-returned?p=0#comment160691
Some documentation: http://our.umbraco.org/documentation/Reference/Mvc/querying
Jeroen
is working on a reply...