Macro Field for Slider Is not Displaying in Content Pages..
Hy All! am newbie in Umbraco.. and facing my issues i Created a XSLT for Slider. macro for this xslt placed in Master Template.. but it is not showing in Content Pages... waiting for your reply... Thanks in advace.. My XSLT is following here
Might need a little more info, but based on your other thread I'm guessing the Slider folder is directly under the Content root, in which case I would probably adjust your XPath to something like this, replacing the doctype alias:
If not, can you provide a bit more info on what isn't working? Is the macro rendering on your pages, it's just not showing any content? Can you show us your content structure?
Macro Field for Slider Is not Displaying in Content Pages..
Hy All!
am newbie in Umbraco.. and facing my issues
i Created a XSLT for Slider. macro for this xslt placed in Master Template..
but it is not showing in Content Pages...
waiting for your reply...
Thanks in advace..
My XSLT is following here
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [ <!ENTITY nbsp " "> ]>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxml="urn:schemas-microsoft-com:xslt"
xmlns:umbraco.library="urn:umbraco.library" xmlns:Exslt.ExsltCommon="urn:Exslt.ExsltCommon" xmlns:Exslt.ExsltDatesAndTimes="urn:Exslt.ExsltDatesAndTimes" xmlns:Exslt.ExsltMath="urn:Exslt.ExsltMath" xmlns:Exslt.ExsltRegularExpressions="urn:Exslt.ExsltRegularExpressions" xmlns:Exslt.ExsltStrings="urn:Exslt.ExsltStrings" xmlns:Exslt.ExsltSets="urn:Exslt.ExsltSets" xmlns:tagsLib="urn:tagsLib" xmlns:BlogLibrary="urn:BlogLibrary"
exclude-result-prefixes="msxml umbraco.library Exslt.ExsltCommon Exslt.ExsltDatesAndTimes Exslt.ExsltMath Exslt.ExsltRegularExpressions Exslt.ExsltStrings Exslt.ExsltSets tagsLib BlogLibrary ">
<xsl:output method="xml" omit-xml-declaration="yes"/>
<xsl:param name="currentPage"/>
<xsl:template match="/">
<!-- start writing XSLT -->
<xsl:variable name="sliderNode" select="$currentPage/parent::*/child::*[@level=1]"/>
<div>
<div id="imageSlider">
<xsl:for-each select="$sliderNode/child::umediaSlider">
<img src="{umbracoFile}" width="100%" height="250" />
</xsl:for-each>
</div>
</div>
</xsl:template>
</xsl:stylesheet>
Hi,
Might need a little more info, but based on your other thread I'm guessing the Slider folder is directly under the Content root, in which case I would probably adjust your XPath to something like this, replacing the doctype alias:
If not, can you provide a bit more info on what isn't working? Is the macro rendering on your pages, it's just not showing any content? Can you show us your content structure?
Thanks,
Tom
Hi Tom!
Thanks...
would you like to give me some links . where can i study XSLT tutorial for Umbraco...
Cheers Azeem Ravi
SkypeName: azeemravi361
Hi Azeem
I hope some of these resources help you to study XSLT in Umbraco CMS
http://our.umbraco.org/wiki/reference/xslt
One of the pages on the wiki for xslt shows the difference between the old and new XML schema
http://our.umbraco.org/wiki/reference/xslt/45-xml-schema/xslt-examples-updated-to-new-schema
And other resource for understanding xslt for Umbraco could be:
http://umbraco.com/help-and-support/video-tutorials/introduction-to-umbraco/sitebuilder-introduction/creating-your-first-xslt-macro/TVPlayer
I hope these resources will help you continue to study XSLT
/Dennis
is working on a reply...