| What is Template Based Display Template Based Display is a very powerful feature that allows you unlimited control over the look and feel of your calendar web pages. This is accomplished by providing you three custom HTML tags as described below. The basic idea is that you create a normal HTML page, containing any HTML code you like such as your menus, page footers, page headers, etc. Into this page you insert custom tags (called <cw_tags in the following). Theses custom tags allow you to include various parts of the calendar in the web page (such as the month grid, calendar menus and program icons for example). Place the file contain these tags in the calendar's data folder and call it template.htm (so the program can find it). From that point on, every time the program runs, it will read the template.htm file and replace any <cw_tags with the HTML code needed to display that object (such as the calendar body for example). Like HTML tags each of the three custom tags has various attributes (name=value pairs) that indicate the options for that tag. For example, the <cw_d> tag has an attribute called 'cmd' which can take on values such as 'calendar', 'todo', or 'contact'. When this tag is processed the HTML code for the calendar, to do list or contact list will be inserted into the web page and the page will be presented to the end user. Details about each of the three tags are presented in the following help pages: An example The simplest possible template.htm file is this: 
      filename: ./data/calweb/template.htmThis will cause the calendar display to appear thus: 
 How is the Template File Selected After creating the template.htm file you have a couple of options on how to use it: 
 Samples There are a number of sample display templates that come with this program. Please look in a folder called ./data/samples.. This folder contains a readme.htm file which will explain how to use the samples. Please see that file for more information. The example of most interest is the file called alltags.htm. This sample shows you an example of every available tag. Case Insensitive: As is true of HTML in general, the tags and options available for the <cw_ tags are case-in-sensitive. This allows you to code to the style of your choice. The Body Tag: Normally the program passes through untouched any text in the file that does not start with <cw_. The HTML <body> tag is a special case. This is the only HTML tag that we process. For the <body> tag we preserve all your optional settings, however if any of the following attributes is not already present we add it. We add these missing items with values picked up from the calweb.ini (the calendar configuration file) found in the calendar folder. The items that are added (if and only if they are not already present) are: 
          bgcolor This is necessary to make our program function properly. |