Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
docs:entities [2012/11/21 10:08] tower [Configuring HTML entities] |
docs:entities [2012/11/21 10:08] (current) tower [Configuring HTML entities] |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ===== Configuring HTML entities ===== | ||
+ | |||
+ | |||
+ | For an explanation of HTML entities, see the [[:configuration#html_entities|configuration]] page. | ||
+ | |||
+ | |||
+ | ==== Adding Entities to the Entities Defintions Array. ==== | ||
+ | |||
+ | |||
+ | You create an Entity definition file with the format illustrated below, and then run the php script ents_seri.php | ||
+ | |||
+ | |||
+ | Name your definitions file add.ent | ||
+ | |||
+ | |||
+ | Then at the command line type: | ||
+ | |||
+ | |||
+ | <code> | ||
+ | php ents_seri.php | ||
+ | </code> | ||
+ | |||
+ | |||
+ | Alternatively, you can give your entity definition file any name you want and feed the file name to the script at the command line: | ||
+ | |||
+ | |||
+ | <code> | ||
+ | php ents_seri.php your_entity_file | ||
+ | </code> | ||
+ | |||
+ | |||
+ | This creates a new entities file called ent.ser, which must then be copied to the fckg/action subdirectory. You would be wise to first back up the original ent.ser before over-writing it. | ||
+ | |||
+ | |||
+ | There are two definition files in the action/entities: ents.data and fcked-ents.data. These are required and must not be removed from the directory. | ||
+ | |||
+ | |||
+ | ==== Format of the entities definition file ==== | ||
+ | |||
+ | |||
+ | The definition file has the following format: | ||
+ | |||
+ | |||
+ | character\\ entity numeric code \\ entity character code | ||
+ | |||
+ | |||
+ | character \\ entity numeric code \\ entity character code | ||
+ | |||
+ | |||
+ | etc. | ||
+ | |||
+ | |||
+ | There is one empty line between each definition. Here is an actual example. | ||
+ | |||
+ | |||
+ | <\\ &''lt'';\\ &''#60''; | ||
+ | |||
+ | |||
+ | ¢ \\ &''#162'';\\ &''cent''; | ||
+ | |||
+ | |||
+ | £ \\ &''#163'';\\ &''pound''; | ||