Templates and views#

Most of what will be public on your website comes from template files that are defined in Silverstripe CMS. Either in the core framework, the modules or themes you install, and your own custom templates.

Silverstripe CMS templates are simple text files that have an .ss extension. They can contain any markup language (e.g. HTML, XML, JSON..) and are processed to add features such as $Var to output variables and logic controls like <% if $Var %>. In this guide we'll look at the syntax of the custom template engine SSViewer and how to render templates from your controllers.

How to's#