Process Overview

Process Overview

Sitecore separates Content from Presentation

There is a 5 step process for building web sites with Sitecore:

  1. Create Data Templates
  2. Create Content Items
  3. Create Presentation Components
  4. Create Layout
  5. Bind Content Items to Presentation Components

Data Templates

  • Provide structure for site content
  • Use Template Manager to define Sections and Fields
  • Assign appropriate field types, and source properties when needed
  • Assign Base Templates to reuse previously created fields
  • Add Standard Values to assign default settings and default values 

Content Items

  • Use Content Editor to create content items from data templates
  • Assign Insert Options to Template Standard Values to make creating multiple items easier
  • Assign $name token to Template Standard Values fields that should have same text as item key
  • Assign static values for field values that should be propagated to each item created from the template
  • Right-click on an item in the Content Tree and use the Insert command to add child items from an assigned data template

Presentation Components

  • Include XSLT Renderings, Sublayouts (User Controls), and Web Controls
  • For XSLT Renderings and Sublayouts, use Developer Center to generate definition item in Content Tree and initial file
  • For Web Controls, use Developer Center to register class name, namespace, and assembly once the class is written
  • Write code using an IDE, such as Visual Studio
  • View XSLT code in Developer Center to see a preview of the presentation

Layouts

  • Web Forms
  • Contain a head section and form tags
  • Contain a definition item in the Content Tree and a file on the filesystem
  • File contains an .aspx extension
  • Add CSS registrations using Developer Center or an IDE, such as Visual Studio

Binding Content Items to Presentation Components

  • Only applies to items that are not already statically referenced on a layout or a sublayout
  • Allows for reuse of Sitecore layouts and sublayouts
  • Developers use Content Editor to create and edit bindings
  • Select Presentation tab > Layout group > Details command to display Device Editor
  • Generally start with Standard Values node of template that item is created from
  • Only use item itself when Standard Values node of template is already configured and you want to specify an exception or a one-off situation
  • Business Users use Page Editor to modify bindings

Development Methodology

  • Sitecore reads data from the Sitecore databases and represents it in memory as XML
  • Developers use the API to access the XML representation
  • Developers do not write SQL statements to access data directly from the Sitecore databases