Content Schedule File

The Content Schedule file contains information that the ContentRotator object uses to manage and display the specified content.

In this file you include any number of HTML content string entries. Each entry consists of two parts: a line that begins with double percentage signs (%%) and contains both the relative weight and any comments, and a second part that contains the HTML content string itself.

Syntax

%% [#Weight] [//Comments]
ContentString
 

Parameters

Weight
This optional parameter specifies a number between 0 and 65,535 that indicates the relative weight of the HTML content string. The probability of a particular content string being displayed by the ContentRotator object can be expressed as the Weight of that content string divided by the sum of Weight values for all entries in the Content Schedule file.

For example, if a Content Schedule file contained three content strings with respective weights of 1, 3, and 4, the Content Rotator displays the first content string one-eighth of the time, the second string three-eighths of the time, and the third string half of the time.

A Weight of 0 will cause a content entry to be ignored.

If Weight is not specified, the default value is 1.

Comments
This optional parameter contains comments about the entry. These comments are for development use only and are not displayed to the user. If you require more than one line of comments, you must start each additional comment line with a line delimiter (%%) followed by a comment delimiter (//).
ContentString
The HTML content that the ContentRotator object displays. For example, you can present a line of text, an image, or a sound.

ContentString may include one or more lines. The ContentRotator object treats everything between blocks of double percent signs (%%) as a single HTML content string.

Example

The following is an example of a Content Schedule file. Note that because the content strings can contain HTML tags, you can display any type of content that can be represented with HTML, including text, images, and hyperlinks.

-------------content.txt--------------------
%% // Because no value is set for Weight, the default value is 1.
Don't run with scissors.

%% #2 // Content can be more that one line long
%% // Additional line of comments 
%% // Yet another line of comments
<FONT FACE="ARIAL,HELVETICA" SIZE="2">
  Let a
  <H1>smile</H1>
  be your umbrella.
</FONT>

%% #3 // This is our favorite image, so show it most often
<IMG SRC="/images/happy.gif">

%% 
Here's the <A HREF="secret.asp">secret link.</A>