This describes the format of PLANG.HST / PLANG4.HST of PHost version 4.1 and 3.5 upwards. Previous versions use an encrypted file format not documented here.

PLANGxx.HST is a container file using the "ar" file format.

 +0   8 BYTEs   Signature, "!<arch>",10
 +8   n RECORDs of variable length, containing the individual languages:
                 +0  16 BYTEs   File name. Terminated with a '/' character
                                or, if none, with a ' '. For PLANGxx.HST,
                                this always has the form "NAME.phl", where
                                "NAME" is the name of the language, in
                                lower case, truncated to 8 characters.
                +16  12 BYTEs   File time, seconds since epoch, decimal.
                +28   6 BYTEs   User Id, decimal.
                +34   6 BYTEs   Group Id, decimal.
                +40   8 BYTEs   File mode (permissions), octal.
                +48  10 BYTEs   File size, decimal.
                +58   2 BYTEs   Signature, "`",10
                +60   n BYTEs   File data
                 +?   1 BYTE    Padding. Only present if file size is odd,
                                to align next record to even position.

The numeric fields are formatted into ASCII numbers using the specified base, and stored left-justified, space-padded. PHost ignores all but the file size field, thus the others are not filled in in the file distributed with PHost.

Format of individual Languages

Each language file, "NAME.phl", consists of a sequence of strings delimited by null characters (ASCII 0).

The first string in each file contains control information in the form of a sequence of assignments:

VERSION=4,LANGUAGE=German,STRINGS=438

- "VERSION=4" marks this as a file for PHost 4.x
- "LANGUAGE=German" contains the spelled-out language name
- "STRINGS=438" contains the number of strings that follow

PHost addresses strings by index, i.e. the fifth string in german.phl is the translation of the fifth string in english.phl. In order to save space, if a string in a language other than English is empty, PHost uses the English string instead.

This is a testing version.
It may be incomplete, and have more bugs (or features) than the public live version at planetscentral.com.