bottleneck testcase based on rubbos
[bottlenecks.git] / rubbos / app / apache2 / manual / mod / mod_imap.html.en
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
4         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
5               This file is generated from xml source: DO NOT EDIT
6         XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
7       -->
8 <title>mod_imap - Apache HTTP Server</title>
9 <link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
10 <link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
11 <link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
12 <link href="../images/favicon.ico" rel="shortcut icon" /></head>
13 <body>
14 <div id="page-header">
15 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
16 <p class="apache">Apache HTTP Server Version 2.0</p>
17 <img alt="" src="../images/feather.gif" /></div>
18 <div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
19 <div id="path">
20 <a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP Server</a> &gt; <a href="http://httpd.apache.org/docs/">Documentation</a> &gt; <a href="../">Version 2.0</a> &gt; <a href="./">Modules</a></div>
21 <div id="page-content">
22 <div id="preamble"><h1>Apache Module mod_imap</h1>
23 <div class="toplang">
24 <p><span>Available Languages: </span><a href="../en/mod/mod_imap.html" title="English">&nbsp;en&nbsp;</a> |
25 <a href="../ko/mod/mod_imap.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a></p>
26 </div>
27 <table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Server-side imagemap processing</td></tr>
28 <tr><th><a href="module-dict.html#Status">Status:</a></th><td>Base</td></tr>
29 <tr><th><a href="module-dict.html#ModuleIdentifier">Module Identifier:</a></th><td>imap_module</td></tr>
30 <tr><th><a href="module-dict.html#SourceFile">Source File:</a></th><td>mod_imap.c</td></tr></table>
31 <h3>Summary</h3>
32
33     <p>This module processes <code>.map</code> files, thereby
34     replacing the functionality of the <code>imagemap</code> CGI
35     program. Any directory or document type configured to use the
36     handler <code>imap-file</code> (using either 
37     <code class="directive"><a href="../mod/mod_mime.html#addhandler">AddHandler</a></code> or
38     <code class="directive"><a href="../mod/core.html#sethandler">SetHandler</a></code>)
39     will be processed by this module.</p>
40
41     <p>The following directive will activate files ending with
42     <code>.map</code> as imagemap files:</p>
43
44     <div class="example"><p><code>AddHandler imap-file map</code></p></div>
45
46     <p>Note that the following is still supported:</p>
47
48     <div class="example"><p><code>AddType application/x-httpd-imap map</code></p></div>
49
50     <p>However, we are trying to phase out "magic MIME types" so we
51     are deprecating this method.</p>
52 </div>
53 <div id="quickview"><h3 class="directives">Directives</h3>
54 <ul id="toc">
55 <li><img alt="" src="../images/down.gif" /> <a href="#imapbase">ImapBase</a></li>
56 <li><img alt="" src="../images/down.gif" /> <a href="#imapdefault">ImapDefault</a></li>
57 <li><img alt="" src="../images/down.gif" /> <a href="#imapmenu">ImapMenu</a></li>
58 </ul>
59 <h3>Topics</h3>
60 <ul id="topics">
61 <li><img alt="" src="../images/down.gif" /> <a href="#features">New Features</a></li>
62 <li><img alt="" src="../images/down.gif" /> <a href="#imapfile">Imagemap File</a></li>
63 <li><img alt="" src="../images/down.gif" /> <a href="#example">Example Mapfile</a></li>
64 <li><img alt="" src="../images/down.gif" /> <a href="#referencing">Referencing your mapfile</a></li>
65 </ul></div>
66 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
67 <div class="section">
68 <h2><a name="features" id="features">New Features</a></h2>
69
70     <p>The imagemap module adds some new features that were not
71     possible with previously distributed imagemap programs.</p>
72
73     <ul>
74       <li>URL references relative to the Referer: information.</li>
75
76       <li>Default <code>&lt;base&gt;</code> assignment through a new map
77       directive <code>base</code>.</li>
78
79       <li>No need for <code>imagemap.conf</code> file.</li>
80
81       <li>Point references.</li>
82
83       <li>Configurable generation of imagemap menus.</li>
84     </ul>
85 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
86 <div class="section">
87 <h2><a name="imapfile" id="imapfile">Imagemap File</a></h2>
88
89     <p>The lines in the imagemap files can have one of several
90     formats:</p>
91
92     <div class="example"><p><code>
93       directive value [<var>x</var>,<var>y</var> ...]<br />
94       directive value "<var>Menu text</var>" [<var>x</var>,<var>y</var>
95       ...]<br />
96       directive value <var>x</var>,<var>y</var> ... "<var>Menu text</var>"
97     </code></p></div>
98
99     <p>The directive is one of <code>base</code>,
100     <code>default</code>, <code>poly</code>, <code>circle</code>,
101     <code>rect</code>, or <code>point</code>. The value is an
102     absolute or relative URL, or one of the special values listed
103     below. The coordinates are <code><var>x</var>,<var>y</var></code>
104     pairs separated by whitespace. The quoted text is used as the text of
105     the link if a imagemap menu is generated. Lines beginning with '#' are
106     comments.</p>
107
108     <h3><a name="imapfile.directives" id="imapfile.directives">Imagemap File Directives</a></h3>
109       <p>There are six directives allowed in the imagemap file. The
110       directives can come in any order, but are processed in the
111       order they are found in the imagemap file.</p>
112
113       <dl>
114       <dt><code>base</code> Directive</dt>
115
116       <dd><p>Has the effect of <code>&lt;base href="<var>value</var>"&gt;
117       </code>. The non-absolute URLs of the map-file are taken relative
118       to this value. The <code>base</code> directive overrides
119       <code class="directive"><a href="#imapbase">ImapBase</a></code> as set in a
120       <code>.htaccess</code> file or in the server configuration files.
121       In the absence of an <code class="directive">ImapBase</code> configuration
122       directive, <code>base</code> defaults to
123       <code>http://server_name/</code>.</p>
124       <p><code>base_uri</code> is synonymous with <code>base</code>.
125       Note that a trailing slash on the URL is significant.</p></dd>
126
127       <dt><code>default</code> Directive</dt>
128
129       <dd>The action taken if the coordinates given do not fit any
130       of the <code>poly</code>, <code>circle</code> or
131       <code>rect</code> directives, and there are no
132       <code>point</code> directives. Defaults to <code>nocontent</code>
133       in the absence of an <code class="directive"><a href="#imapdefault">ImapDefault</a></code> configuration setting, causing a status
134       code of <code>204 No Content</code> to be returned. The client
135       should keep the same page displayed.</dd>
136
137       <dt><code>poly</code> Directive</dt>
138
139       <dd>Takes three to one-hundred points, and is obeyed if the
140       user selected coordinates fall within the polygon defined by
141       these points.</dd>
142
143       <dt><code>circle</code></dt>
144
145       <dd>Takes the center coordinates of a circle and a point on
146       the circle. Is obeyed if the user selected point is with the
147       circle.</dd>
148
149       <dt><code>rect</code> Directive</dt>
150
151       <dd>Takes the coordinates of two opposing corners of a
152       rectangle. Obeyed if the point selected is within this
153       rectangle.</dd>
154
155       <dt><code>point</code> Directive</dt>
156
157       <dd>Takes a single point. The point directive closest to the
158       user selected point is obeyed if no other directives are
159       satisfied. Note that <code>default</code> will not be
160       followed if a <code>point</code> directive is present and
161       valid coordinates are given.</dd>
162       </dl>
163     
164
165     <h3><a name="imapfile.values" id="imapfile.values">Values</a></h3>
166
167       <p>The values for each of the directives can any of the following:</p>
168
169       <dl>
170       <dt>a URL</dt>
171
172       <dd><p>The URL can be relative or absolute URL. Relative URLs
173       can contain '..' syntax and will be resolved relative to the
174       <code>base</code> value.</p>
175       <p><code>base</code> itself will not resolved according to the
176       current value. A statement <code>base mailto:</code> will
177       work properly, though.</p></dd>
178
179       <dt><code>map</code></dt>
180
181       <dd>Equivalent to the URL of the imagemap file itself. No
182       coordinates are sent with this, so a menu will be generated
183       unless <code class="directive"><a href="#imapmenu">ImapMenu</a></code> is set to
184       <code>none</code>.</dd>
185
186       <dt><code>menu</code></dt>
187       <dd>Synonymous with <code>map</code>.</dd>
188
189       <dt><code>referer</code></dt>
190
191       <dd>Equivalent to the URL of the referring document. Defaults
192       to <code>http://servername/</code> if no <code>Referer:</code>
193       header was present.</dd>
194
195       <dt><code>nocontent</code></dt>
196
197       <dd>Sends a status code of <code>204 No Content</code>,
198       telling the client to keep the same page displayed. Valid for
199       all but <code>base</code>.</dd>
200
201       <dt><code>error</code></dt>
202
203       <dd>Fails with a <code>500 Server Error</code>. Valid for all
204       but <code>base</code>, but sort of silly for anything but
205       <code>default</code>.</dd>
206       </dl>
207     
208
209     <h3><a name="imapfile.coords" id="imapfile.coords">Coordinates</a></h3>
210
211       <dl>
212       <dt><code>0,0 200,200</code></dt>
213
214       <dd>A coordinate consists of an <var>x</var> and a <var>y</var>
215       value separated by a comma. The coordinates are separated
216       from each other by whitespace. To accommodate the way Lynx
217       handles imagemaps, should a user select the coordinate
218       <code>0,0</code>, it is as if no coordinate had been
219       selected.</dd>
220       </dl>
221
222     
223
224     <h3><a name="imapfile.quotedtext" id="imapfile.quotedtext">Quoted Text</a></h3>
225
226       <dl>
227       <dt><code>"<var>Menu Text</var>"</code></dt>
228
229       <dd><p>After the value or after the coordinates, the line
230       optionally may contain text within double quotes. This string
231       is used as the text for the link if a menu is
232       generated:</p>
233
234       <div class="example"><p><code>
235         &lt;a href="http://foo.com/"&gt;<var>Menu text</var>&lt;/a&gt;
236       </code></p></div>
237
238       <p>If no quoted text is present, the name of the link will be
239       used as the text:</p>
240
241       <div class="example"><p><code>
242         &lt;a href="http://foo.com/"&gt;http://foo.com&lt;/a&gt;
243       </code></p></div>
244
245       <p>If you want to use double quotes within this text, you have to
246       write them as <code>&amp;quot;</code>.</p></dd>
247       </dl>
248
249     
250 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
251 <div class="section">
252 <h2><a name="example" id="example">Example Mapfile</a></h2>
253
254     <div class="example"><p><code>
255       #Comments are printed in a 'formatted' or 'semiformatted' menu.<br />
256       #And can contain html tags. &lt;hr&gt;<br />
257       base referer<br />
258       poly map "Could I have a menu, please?" 0,0 0,10 10,10 10,0<br />
259       rect .. 0,0 77,27 "the directory of the referer"<br />
260       circle http://www.inetnebr.com/lincoln/feedback/ 195,0 305,27<br />
261       rect another_file "in same directory as referer" 306,0 419,27<br />
262       point http://www.zyzzyva.com/ 100,100<br />
263       point http://www.tripod.com/ 200,200<br />
264       rect mailto:nate@tripod.com 100,150 200,0 "Bugs?"<br />
265     </code></p></div>
266
267 </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
268 <div class="section">
269 <h2><a name="referencing" id="referencing">Referencing your mapfile</a></h2>
270
271     <div class="example"><h3>HTML example</h3><p><code>
272       &lt;a href="/maps/imagemap1.map"&gt;<br />
273       <span class="indent">
274         &lt;img ismap src="/images/imagemap1.gif"&gt;<br />
275       </span>
276       &lt;/a&gt;
277     </code></p></div>
278
279     <div class="example"><h3>XHTML example</h3><p><code>
280       &lt;a href="/maps/imagemap1.map"&gt;<br />
281       <span class="indent">
282         &lt;img ismap="ismap" src="/images/imagemap1.gif" /&gt;<br />
283       </span>
284       &lt;/a&gt;
285     </code></p></div>
286
287 </div>
288 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
289 <div class="directive-section"><h2><a name="ImapBase" id="ImapBase">ImapBase</a> <a name="imapbase" id="imapbase">Directive</a></h2>
290 <table class="directive">
291 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Default <code>base</code> for imagemap files</td></tr>
292 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ImapBase map|referer|<var>URL</var></code></td></tr>
293 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ImapBase http://servername/</code></td></tr>
294 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
295 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Indexes</td></tr>
296 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
297 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_imap</td></tr>
298 </table>
299     <p>The <code class="directive">ImapBase</code> directive sets the default
300     <code>base</code> used in the imagemap files. Its value is
301     overridden by a <code>base</code> directive within the imagemap
302     file. If not present, the <code>base</code> defaults to
303     <code>http://<var>servername</var>/</code>.</p>
304
305 <h3>See also</h3>
306 <ul>
307 <li><code class="directive"><a href="../mod/core.html#usecanonicalname">UseCanonicalName</a></code></li>
308 </ul>
309 </div>
310 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
311 <div class="directive-section"><h2><a name="ImapDefault" id="ImapDefault">ImapDefault</a> <a name="imapdefault" id="imapdefault">Directive</a></h2>
312 <table class="directive">
313 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Default action when an imagemap is called with coordinates
314 that are not explicitly mapped</td></tr>
315 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ImapDefault error|nocontent|map|referer|<var>URL</var></code></td></tr>
316 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ImapDefault nocontent</code></td></tr>
317 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
318 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Indexes</td></tr>
319 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
320 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_imap</td></tr>
321 </table>
322     <p>The <code class="directive">ImapDefault</code> directive sets the default
323     <code>default</code> used in the imagemap files. Its value is
324     overridden by a <code>default</code> directive within the
325     imagemap file. If not present, the <code>default</code> action
326     is <code>nocontent</code>, which means that a <code>204 No
327     Content</code> is sent to the client. In this case, the client
328     should continue to display the original page.</p>
329
330 </div>
331 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
332 <div class="directive-section"><h2><a name="ImapMenu" id="ImapMenu">ImapMenu</a> <a name="imapmenu" id="imapmenu">Directive</a></h2>
333 <table class="directive">
334 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Action if no coordinates are given when calling
335 an imagemap</td></tr>
336 <tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ImapMenu none|formatted|semiformatted|unformatted</code></td></tr>
337 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
338 <tr><th><a href="directive-dict.html#Override">Override:</a></th><td>Indexes</td></tr>
339 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
340 <tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_imap</td></tr>
341 </table>
342     <p>The <code class="directive">ImapMenu</code> directive determines the
343     action taken if an imagemap file is called without valid
344     coordinates.</p>
345
346     <dl>
347       <dt><code>none</code></dt>
348       <dd>If ImapMenu is <code>none</code>, no menu is generated,
349       and the <code>default</code> action is performed.</dd>
350
351       <dt><code>formatted</code></dt>
352       <dd>A <code>formatted</code> menu is the simplest menu.
353       Comments in the imagemap file are ignored. A level one header
354       is printed, then an hrule, then the links each on a separate
355       line. The menu has a consistent, plain look close to that of
356       a directory listing.</dd>
357
358       <dt><code>semiformatted</code></dt>
359       <dd>In the <code>semiformatted</code> menu, comments are
360       printed where they occur in the imagemap file. Blank lines
361       are turned into HTML breaks. No header or hrule is printed,
362       but otherwise the menu is the same as a
363       <code>formatted</code> menu.</dd>
364
365       <dt><code>unformatted</code></dt>
366       <dd>Comments are printed, blank lines are ignored. Nothing is
367       printed that does not appear in the imagemap file. All breaks
368       and headers must be included as comments in the imagemap
369       file. This gives you the most flexibility over the appearance
370       of your menus, but requires you to treat your map files as
371       HTML instead of plaintext.</dd>
372     </dl>
373
374 </div>
375 </div>
376 <div class="bottomlang">
377 <p><span>Available Languages: </span><a href="../en/mod/mod_imap.html" title="English">&nbsp;en&nbsp;</a> |
378 <a href="../ko/mod/mod_imap.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a></p>
379 </div><div id="footer">
380 <p class="apache">Copyright 2009 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
381 <p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div>
382 </body></html>