| iMatix home page | htmlpp home page | << | < | > | >> | htmlpp Version 4.2a

# htmlpp - The HTML Preprocessor

- Overview
- Installing Htmlpp
  - Getting Htmlpp
  - Installation Under Unix
  - Installation Under MS-DOS
  - Installation Under 32-bit Windows
- Getting Started
- Htmlpp Reference
  - Description
  - Command-line Syntax
  - Inserting Symbols
  - Types of Symbol
  - Standard Symbols
  - Htmlpp Commands
  - Htmlpp Macro Processing
  - Multilingual support
    - Support For Accented Characters
    - Dates Formatting
    - Multilingual Variables
    - Generating Several Language Versions from a Single Source File
  - Htmlpp Guru Mode
    - Standard Guru Mode Definitions
    - Chapter and Section Headers
    - Table of Contents
    - Pagination
    - Page Headers and Footers
    - Paragraphs
    - Preformatted Text
    - Bulleted and Numbered Lists
    - Definition Lists
    - Tables
    - Figures and Images
    - Hyperlinks
    - Special Characters
  - Htmlpp Intrinsic Functions
    - The &date Function
    - The &time Function
    - The &week_day Function
    - The &year_week Function
    - The &julian_date Function
    - The &lillian_date Function
    - The &date_to_days Function
    - The &days_to_date Function
    - The &future_date Function
    - The &past_date Function
    - The &date_diff Function
    - The &image_width Function
    - The &image_height Function
    - The &file_size Function
    - The &file_date Function
    - The &file_time Function
    - The &normalise Function
    - The &system Function
    - The &upper Function
    - The &lower Function
    - The &pageref Function
    - The &relpath Function
  - Multipass Processing
  - Multipass Debugging
  - Other Things to Know
- Frequently Asked Questions
  - Why does my .if command not work?
  - Why does my .if command still not work?
  - How do I install htmlpp on UNIX?
  - How do I change the .htm extension to .html?
  - Do you know of any good link checkers?
- Other Information
  - Product History

## Overview

An article in the December 1997 issue of Linux Journal describes htmlpp, and is a good introduction to this tool.

What is htmlpp?

- Htmlpp is a pre-processor for HTML documents.
- Its purpose is to simplify the work of writing and packaging large numbers of HTML documents.
- It acts like a compiler: you provide an input source text and htmlpp produces the HTML documents from that. This is easier and safer than trying to edit and manage separate HTML documents.
- To use htmlpp, you should be comfortable writing HTML without help from a special HTML editor. This is not usually a problem, since HTML is a simple language.
- Htmlpp is free software written in Perl, and copyright (c) 1996-97 iMatix. It is distributed with full sources according to the GNU General Public License.

What does htmlpp do?

- It breaks one input source text file into several HTML documents. Typically you will want to edit a larger file (it is faster and easier), but provide the information in smaller pieces on-line (people can access it easier). Htmlpp makes this possible.
- It lets you define symbols like `version` in one place, then use these in the text like this: `$(version)` so that you can make changes in a single place only, not throughout the text.
- It creates tables of contents, and links to chain pages together in sequence.
- It adds headers and footers to pages, so that you can keep a consistent style in all HTML pages.
- It lets you define macros to simplify HTML markup.
- It converts plain text into HTML using guru mode.
- It converts accented characters into HTML metacharacters.
- It allows you to embed Perl code and to include the output of any external program into the page.
- It queries flat-text databases.
- It provides features to build multilingual sites.
- It provides many built-in functions to simplify HTML writing, like calculating image dimensions, file sizes, working with dates, etc.

How do I use htmlpp?

- Take a look at htmlpp.txt, which is the documentation source for htmlpp's own on-line documentation. This is the main example for htmlpp.
- The files in `template.zip` provide the basic template for a new project. This zip file is provided as part of the htmlpp package.
- Edit the source text using any text editor, then run htmlpp on the source. It produces a number of HTML files (extension .htm) which you can test using a browser.
- In general, htmlpp generates HTML pages that use relative addressing, so that pages refer to each other without specifying a host or path. This allows you to test and use the HTML pages on a local hard disk.

Where do I get htmlpp?

- Htmlpp is available from the iMatix website as a zip file for Windows or DOS or OS/2 and as a tgz file for UNIX. Both contain the same files.

What else should I know?

- Htmlpp uses Perl 4 or Perl 5. It does not use any system-specific features, so will run on any box (I wrote it mostly under MS-DOS; it's been used on heavily on UNIX and OS/2).
- Perl is a programming language written by Larry Wall that is freely available for many platforms. If you never installed or used Perl, this is an excellent time to start.
- Under MS-DOS, you will need Big Perl to process large documents.

What Are The Alternatives?

- A lot of work by hand.
- A number of other products work somewhat like htmlpp. Take a look at the eponymously named htmlpp at http://www.eleves.ens.fr:8080/home/nthiery.

| << | < | > | >> | htmlpp - The HTML Preprocessor | Installing Htmlpp | Getting Started | Htmlpp Reference | Frequently Asked Questions | Other Information | Copyright © 1996-97 iMatix