Follow

Managing Templates Overview

Templates can also be called Theme's. This is the file where we add the js and css. 

Usually a Theme will have a Master Page. The Master page will define the HTML, language, meta data and favicon. The Theme will pass the css and js to the Master page.

 

In Base Theme (BaseTheme.ascx), which come out-of-box, the css and js will come from the CMS, as defined in Site Configuration.

If you want to create another Theme, you can get the resources from CMS, as above, but the style will be the same. You might have to add style sheets statically into the theme folder.

 

Folder: ~/Templates/websitetempalte

Base Theme

Base Theme has some key features.

BaseTheme.ascx

  1. Implements Master Page File
  2. Has a top style Resource Control to output the CSS files [TODO LINK to page with description on this]
  3. Sets Properties for Advantage Page Name - this will be the Drop Down text within the CMS
  4. Has a bottom Resource Control to output JS files [TODO LINK to a page with desc on this]
  5. Has a Content Place Holder for Bottom Javascript Content

 

BaseTheme.ascx.cs

  1. Inherits from AdvantagePageTemplate
  2. Defines the Zone Container
  3. Fills the top Resource Control with CSS - these values are from Site Configuration: note, there are 2 setups here - Base Theme section and Style Sheets section.
  4. Fills the bottom Resource Control with JS - these values are from Site Configuration: note, there are 2 setups here - Base Theme section and Javascript Files section.

Creating a Template File

You can modify the template that exists, or setup a new one. Please make sure to read the steps above. Here are the important things to note:

  1. The AdvantagePageName should be set as a different string key to prevent confusion
Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments