From d7d1b3f2a09bbae5aedd9596bb5919b0658666d6 Mon Sep 17 00:00:00 2001
From: Rune Hem Strand Templating in Umbraco builds on the concept of Razor Views from asp.net MVC. - This tour is a sneak peak on how to write templates in Umbraco. In this tour we will learn how to render content from our Home document type so we can see the content added to our Home page. Templating in Umbraco builds on the concept of Razor Views from asp.net MVC. - This tour is a sneak peak on how to write templates in Umbraco. In this tour you will learn how to render content from the Home Page document type so you can see the content added to our Home
Click the Home template to open and edit it.
", - eventElement: "#tree [data-element='tree-item-templates'] [data-element='tree-item-Home'] a.umb-tree-item__label", + content: "Click the Home Page template to open and edit it.
", + eventElement: "#tree [data-element='tree-item-templates'] [data-element='tree-item-Home Page'] a.umb-tree-item__label", event: "click" }, { element: "[data-element='editor-templates'] [data-element='code-editor']", title: "Edit template", - content: 'The template can be edited here or in your favorite code editor.
To render the field from the document type add the following to the template:
@Model.Content.GetPropertyValue("welcomeText")'
+ content: 'The template can be edited here or in your favorite code editor.
To render the field from the document type add the following to the template:
<h1>@Model.Content.Name</h1>' }, { element: "[data-element='editor-templates'] [data-element='button-save']",
<p>@Model.Content.WelcomeText</p>