Appendix 4 - The Apache manual
|
The official thesaurus of Apache concepts and procedures is set up in the manual directory, by the standard Apache installation process. The documents it contains are multilingual, i.e. one document can exist in different language versions: English, German, French, Spanish, Russian, Japanese, Chinese, Korean, etc... A part from English, not all the languages have a version for every document though.
The documents can be in HTML or XML format. A presentation is given below for HTML documents. It can be repeated identically for XML documents.
It is advisable that you have a look at the contents of the manual directory before reading the following.
1. Multilanguage documentation |
1.1 Language versions and type map |
In HTML format, a certain document can have, for example, these versions:
docu.html.en | in English |
docu.html.de | in German |
docu.html.es | in Spanish |
docu.html.fr | in French |
For each such group, there is a so-called type map document which contains the URI of the different versions along with their language and their content-type properties. Here, the name of this type map is the common part of the different version names, docu.html with the above example.
The .html extension notwithstanding, this is a text file, not an HTML page. You can display one of them to see (normally, double-clicking on it would display it in a user presentation form; from this display, you can display the source, as for a regular HTML page).
1.2 The negotiation function |
![]() |
1.3 Editing the configuration file |
<Directory manual> AddHandler type-map html </Directory> |
to declare the .html extension as a type-map extension for all files contained in the manual directory and below.
2. A local single language version |
As the manual directory is not contained in the document root, to allow access to it, you have to define an alias. For example:
Alias /manual/ C:/Apache2/manual/ | under Windows |
or | |
Alias /manual/ /user/apache2/manual/ | under UNIX |
If Apache is in your local computer, you can then access a document from the Apache thesaurus through a request like:
http://localhost/manual/mod/docu.html |
You cannot display a document by double-clicking on its type-map (namely, docu.html in the example). As of September 2004, when you double-click on the English (or any other language) version of the document:
docu.html.en
it is not displayed as an HTML document should.
If you are sure you need the English version only, you can setup a version of the thesaurus on your computer where the documents can be accessed by a double click.
2.1 Procedure outline |
1. | Copy the manual directory to your computer (if it is already in your computer, make a copy of it), and apply the described changes to the copied version -- it is not recommended to modify the original version which should be maintained |
2. | Remove the type-map files (or change their extension to other than .html) |
3. | Change all the .html.en extensions to .html |
2.2 The ChangeExtension utility |
You have first to point the CLASSPATH environment variable to the classes directory.
The ChangeExtension utility is called using the command (from any directory):
java tools.ChangeExtension |
Old extension: .html New extension: .sav |
- | the current directory is displayed in the line labelled 'File name", near the box bottom |
- | to go up one level in the tree, click on the icone with an upward arrow, on the box top row |
- | to go down on a directory and make it current, double-click on it |
- | when you are satisfied with the current directory, select it by clicking on the "Open" button |
Proceed on to modify these files? (Y/N) |
2.3 Changing the file extensions |
Lest you mistakenly change the .html extensions remaining after the .en are removed, it is advisable to change the original .html to something else, in all of the directories first. Only then, remove the .en suffixes.
2.3.1 Changing the type map extension |
Old extension: .html New extension: .save Change .html to .save ? (Y/N) |
A few lines intended to guide those who did not read this document are
displayed. Press the Then continue to the end.
2.3.2 Removing the .en
extension You start with a screen like this:
Previous Next Contents Glossary Index References Cover License
Next, you have to remove the .en
suffix from the file names. You do it by entering:
- .en as the old
extension
- nothing as the new extension (just press the
Confirm by entering "Y" or "y"
(type the letter and press the
Old extension: .en
New extension:
Change .en to ? (Y/N)