The INF File

It is important to have a meaningful title and description for a page or web or frames template, since a list of wizards and templates could be quite large. This information is kept in an INF file inside the template directory. The base name of this file must match the base name of the template directory. For example, you would create sample.inf inside the sample.tem directory.

The INF file is in standard Windows INI file format. The INF file can have several named sections, each surrounded by angle brackets like this: [Section Name]. Underneath each section are name-value pairs, one on each line. An attribute name (also called a key) and its value are separated by an equal sign (=).

The Info Section

FrontPage reads the [info] section of the INF file when it presents a list of wizards and templates to a user. If the INF file is not found, or if the [info] section does not exist, FrontPage displays the base name of the template directory (such as sample). If the INF file is found, the dialog boxes display the values of the title and description keys found in the [info] section.

Here’s what an INF file for the sample template might look like:

[info]

title=My Sample Page
description=Create a page from a template.

There can be other keys depending on the template type. For example, a frames template should have a “layout” key as described above.

In FrontPage 98, a web template can have two new keys in the info section: “theme” and “border”. The theme key can contain the name of an installed theme along with its parameters (Vivid Colors, Active Graphics, Image Background) specified as a 3-digit number. For example, “theme=citrus 101” means that the template will use the Citrus theme with Vivid Colors and an Image Background. The border key can contains one or more letter from the string “tlrb” (TLRB), where the letters represent the four possible borders a page can have: top, left, right, and bottom. If these keys are present, the specified theme and borders will be applied to the web after the pages have been uploaded.

Web templates can also specify three optional sections that are used by the FrontPage Explorer when loading web templates: [FileList], [MetaInfo], and [TaskList].

The FileList Section

The [FileList] section allows explicit mappings between the file names inside the template directory and the web-relative URLs where they will be uploaded. It also allows you to upload files from subdirectories of the web template. Each line has the form filename=URL.

When you do not provide a [FileList] section, the FrontPage Explorer scans the template directory and uploads all available files. However, it does not descend into subdirectories. All file names are converted to lowercase, and the URLs are set to be the same as the file names.

When you provide a [FileList], only the files mentioned in the section are uploaded. The URLs have the exact case as specified.

When you specify only the file name, the URL will be the same as the file name. Entries must still include the equal sign, like this:

[FileList]

   fileone.htm=
   filetwo.htm=

You may refer to files in template subdirectories when creating a [FileList] section. You must use forward-slashes when specifying these directories in URLs.

The MetaInfo Section

A web can have some persistent meta-info variables, which are a set of name-value pairs stored inside each web. These variables can be used to store configuration information about the web, or when used in conjunction with the Substitution Component, to replace instances of certain strings in all your web pages. You may define a number of these variables in the optional [MetaInfo] section. Keys are case-insensitive. Names beginning with vti_ are reserved for web administration. Each line has the form name=value.

A sample [MetaInfo] section might look like this:

[MetaInfo]

CompanyName=Microsoft

CompanyAddress=One Microsoft Way, Redmond Washington

The TaskList Section

You can upload some tasks for the FrontPage To Do List using items in the optional [TaskList] section. A task consists of six attributes:

  1. TaskName

  2. Priority (1 to 3)

  3. CreatedBy

  4. URL

  5. Cookie

  6. Comment

These attributes are encoded in each line of the [TaskInfo] section as follows:

   TaskNum=TaskName|Priority|CreatedBy|URL|Cookie|Comment

TaskNum is a unique key, such as ‘t01’, ‘t02’, etc. Task attributes are separated by vertical bar characters (‘|’).

task attribute description
TaskName a short phrase, typically 3 or 4 words, telling the user what to do
Priority an integer, where 1=High, 2=Medium, and 3=Low
CreatedBy the name of the template creating the task
URL the page or image the task refers to, such as news.htm or logo.gif
Cookie an additional identifier for a point within the target URL; currently limited to HTML bookmarks, specified as #bookmark
Comment a few words describing in detail what needs to be done; cannot contain any new-line characters