2 <!DOCTYPE modulesynopsis SYSTEM "../style/modulesynopsis.dtd">
3 <?xml-stylesheet type="text/xsl" href="../style/manual.en.xsl"?>
4 <!-- $LastChangedRevision$ -->
7 Copyright 2002-2005 The Apache Software Foundation or its licensors, as
10 Licensed under the Apache License, Version 2.0 (the "License");
11 you may not use this file except in compliance with the License.
12 You may obtain a copy of the License at
14 http://www.apache.org/licenses/LICENSE-2.0
16 Unless required by applicable law or agreed to in writing, software
17 distributed under the License is distributed on an "AS IS" BASIS,
18 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 See the License for the specific language governing permissions and
20 limitations under the License.
23 <modulesynopsis metafile="mod_asis.xml.meta">
26 <description>Sends files that contain their own
27 HTTP headers</description>
29 <sourcefile>mod_asis.c</sourcefile>
30 <identifier>asis_module</identifier>
33 <p>This module provides the handler <code>send-as-is</code>
34 which causes Apache to send the document without adding most of
35 the usual HTTP headers.</p>
37 <p>This can be used to send any kind of data from the server,
38 including redirects and other special HTTP responses, without
39 requiring a cgi-script or an nph script.</p>
41 <p>For historical reasons, this module will also process any
42 file with the mime type <code>httpd/send-as-is</code>.</p>
45 <seealso><module>mod_headers</module></seealso>
46 <seealso><module>mod_cern_meta</module></seealso>
47 <seealso><a href="../handler.html">Apache's Handler Use</a></seealso>
49 <section id="usage"><title>Usage</title>
51 <p>In the server configuration file, associate files with the
52 <code>send-as-is</code> handler <em>e.g.</em></p>
54 <example>AddHandler send-as-is asis</example>
56 <p>The contents of any file with a <code>.asis</code> extension
57 will then be sent by Apache to the client with almost no
58 changes. Clients will need HTTP headers to be attached, so do
59 not forget them. A Status: header is also required; the data
60 should be the 3-digit HTTP response code, followed by a textual
63 <p>Here's an example of a file whose contents are sent <em>as
64 is</em> so as to tell the client that a file has
69 Status: 301 Now where did I leave that URL<br />
70 Location: http://xyz.abc.com/foo/bar.html<br />
71 Content-type: text/html<br />
75 <title>Lame excuses'R'us</title><br />
78 <h1>Fred's exceptionally wonderful page has moved to<br />
79 <a href="http://xyz.abc.com/foo/bar.html">Joe's</a>
86 <note><title>Notes:</title>
87 <p>The server always adds a <code>Date:</code> and <code>Server:</code>
88 header to the data returned to the client, so these should not be
89 included in the file. The server does <em>not</em> add a
90 <code>Last-Modified</code> header; it probably should.</p>