We have already described the content delivery model in Umbraco in my earlier post. So now let’s see how XSLT is used to created html out of the generated Umbraco XML content. In Umbraco the XML is generated based on the Document type alias and properties type alias.
This is a Sample XML generated (based on the Runway package). Here you can see the XML nodes created based on the RunwayHomepage and RunwayTextpage Document types. Also you can see the corresponding properties alias like bodyText, siteName , siteDescription etc.
I have already defined XSLT in my earlier post. It’s very easy to create an XSLT in Umbraco. Just follow the steps given
• Go to developer section
• Right click XSLT
• Create – file name and choose a template
• You are done
Following are the benefits of XSLT out of the box in Umbraco
• Insanely fast compiled code
• Easy to edit
• Caching is free
• Flexible and reusable
• Generates nice (x)html
• Easy to extend and ships with helpful libraries
An empty XSLT file created out of the box in Umbraco looks like as follows
You can write the code logic inside the marked section in the above code. You can use for each , if else , Umbraco libraries etc inside the XSLT to implement a functionality.
Please feel free to watch a good video demonstration in the following url http://umbraco.org/help-and-support/video-tutorials/umbraco-fundamentals/xslt-in-umbraco-45/xslt-and-umbraco
About .NET , C#, ASP.NET , SharePoint , Umbraco , SQL Server , Business Intelligence and more...
Subscribe to:
Post Comments (Atom)
Installing ASP.NET MVC
Installing ASP.NET MVC Before we dive deep into the ASP.NET MVC, let’s install it our development machine. This is very straight forwa...
-
Here lets discuss about the various Parameter modifiers that can be used to manage how arguments are passed to methods. Default by Value...
-
When you begin developing Windows Phone applications, you need to choose a framework one from Silverlight or XNA framework. Let’s list down ...
-
Visual Studio Test Professional 2010 is an integrated testing toolset from Microsoft which provides a complete plan-test-track workflow for ...
No comments:
Post a Comment