1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114
|
WN version 1.17.3
This file documents the format of an index.cache file for WN.
Parameters in a record of an index file like
File=foo.html
Title=This is foo
Keywords=bar, baz
get translated to a line in the index.cache file like
file=foo.html&title=This is foo&keywords=bar, baz
i.e. a sequence of token=value pairs separated by ampersands. Any
ampersands in a value must be escaped with a '\' which will be removed
when the server reads the index.cache file. All lines in an index.cache
file are terminated with a single '\n' (newline) character. (This is
UNIX after all).
The first line of an index.cache file is the directory record line,
the second line should be blank. If there is no directory record
line the first line should be blank and file information can start
with the second line.
Here is a list of the elements of an index file and the corresponding
tokens used in the index.cache file.
Directory Record Cache token
---------------- -----------
Accessfile accessfile
Searchwrapper dwrapper
Nomatchsub nomatchsub
Subdirs subdirs
Owner owner
Cache-module cachemod /* Cache data base module */
File-module filemod /* File data base module */
Search-module indexmod /* Index search module module */
Authorization-type authtype /* Type of authorization */
Authorization-realm authrealm /* Realm for authorization */
Authorization-module authmod /* module to do authorization */
Auth-denied-file authdenied_file
Default-Content default_content <see note 1>
Default-Document default_document
Default-Max-Age default_maxage <see note 4>
Attributes <see note 3>
Default-Attributes defattributes <see note 3>
No-such-file-URL nofile_url
Access-denied-URL noaccess_url
File Record Cache Token
----------- -----------
File file
IndexFile file
Title title
URL url
Header header /* HTTP header line added for item */
Parse parse /* boolean */
Redirect redirect
Keywords keywords
Content-Type content
Content-Encoding encoding
Field# field# /* e.g. field7 */
Includes includes
Wrappers wrappers
Searchwrapper swrapper
Nomatchsub nomatchsub
Filter filter
Expires expires
Attributes <see note 2>
Set-Cookie setcookie
Refresh refresh
Max-Age maxage <see note 4>
<Note 1> The Default-content line is used to specify the content-type of
files for which no Content-type record is present. By default this has
the value "text/plain".
<Note 2> "Attributes=" lines in a file record (or in their absence
"Default-Attributes=" lines in the directory record) get translated
into a numeric value which is the sum of the numbers corresponding
to the items below marked with an (*). An ASCII representation of
this number prceded by "attributes=" is the item in the index.cache
file. For example the entry "Attributes=nondynamic, parse, cgi" in
an index file is converted to the entry "attributes=642" (since
642=2+128+512) and "Default-attributes=nondynamic, parse, cgi" is
converted to "defattributes=642".
Items not marked with an (*) should not have their numeric values
added as this is done by the server when it reads e.g. the include
or wrapper line.
dynamic* (1)
nondynamic* (2)
include (4)
wrapped (8)
swrapped (16)
filtered (32)
nosearch* (64)
parse* (128)
noparse* (256)
cgi* (512)
ismap* (1024)
<Note 3> In the directory record Attributes=nosearch is translated to
nosearch=true and Attributes=serveall is translates to serveall=true.
<Note 4> The maxage and default_maxage lines have the format
"maxage=12345" to indicate 12345 seconds after the document is
served or "maxage=L12345" to indicate 12345 seconds after the
last modification date of the document. All times must be converted
to seconds before being put in the index.cache file.
|