HTML Templates

<< Click to Display Table of Contents >>

Navigation:  Reference > Project Structure & Templates >

HTML Templates

Help+Manual uses editable HTML files referred to as "templates" to define the basic layout of your topic pages in your published output. There are templates for your topic pages that are used for all HTML-based output formats and additional templates that are only used for WebHelp output, which are used to define the overall layout (frameset) and the Table of Contents, Search and Index panes in the WebHelp help system generated by Help+Manual.

If you are using an HTML skin you must edit your templates and settings in the skin!

Nowadays you will almost always choose an HTML skin to publish your project to WebHelp or HTML Help/CHM. A skin is a special kind of Help+Manual project without topics that only stores your HTML templates and all the settings relevant for HTML output to these two formats. When you choose a skin, the templates and settings in the skin completely replace those in your project.

Normally, a skin is pre-designed and you don't need to change anything. However, if you do want to change something, you must do all your editing in the .hmskin skin file. Editing in your Help+Manual project won't have any effect because those templates and settings are not used.

To edit a skin, make a copy of the .hmskin skin file in your project folder and then open it in Help+Manual by selecting .hmskin as the file type to open in the Open dialog. All the templates and settings are in the same places as in a normal Help+Manual project.

Exception: HTML Export Options

The HTML Export Options section is not stored in skins and needs to be edited in your project.

HTML templates are not help windows!

HTML topic page templates and help windows are completely separate. Help windows are only relevant in HTML Help (CHM), where they are used to configure the help viewer and for opening linked topics in external windows.

HTML topic page templates can be assigned to individual topics in the Topic Options tab on the left of the main editor window. Help windows cannot be assigned to individual topics, you can only use them in hyperlinks.

HTML topic page templates

These templates define the layout and appearance of your topic pages in all HTML-based output formats, including the background colors of the topic and the topic header.

By default there is one HTML topic page template called Default that is assigned to all topics. You can edit this template and you can also define as many additional templates as you like and assign them to individual topics, by selecting them in the HTML Page Template: field in the Topic Options tab on the left of the main editor window.

The HTML topic page templates can be accessed in Configuration > HTML Page Templates in the Project Explorer. See Using HTML Templates for more details.

How topic page templates work

If you are familiar with HTML, you will know that HTML pages consist of a number of standard sections. The visible content of the page is stored between the <body> and </body> tags. The general page definition and any additional functions (for  example the page title, keywords, scripts, search engine information etc.) are stored in the other sections above and sometimes also below this main body section.

When you publish your project to HTML-based output formats the HTML pages for your topics are "assembled" from two components: The HTML page template is taken as the framework and the content from the Help+Manual editor is inserted in this template between the <body> and </body> tags. Individual content outside the body section is inserted with variables. The content of your topics is also inserted by a variable called <%TOPIC_TEXT%>.

Additional WebHelp templates

In addition to the HTML topic page templates there are also four additional HTML templates that are used to configure your WebHelp output. These templates define the layout of the entire help (frameset) and the pages for the Table of Contents, Search and Index panes in your WebHelp output.

These templates can be accessed in Configuration > Publishing Options > WebHelp in the Project Explorer. Unlike the topic page templates, there is only one copy of each of these WebHelp templates per project, you cannot define additional versions as you can for HTML topic page templates. However, you can apply different versions to your output with "skins". See Transforming your Output with Skins for details and instructions.

See also:

Using HTML Templates

Templates in Help+Manual

Using help windows