mod_asis.html revision 57fad287a8bc02321dfbb74280dd4d6540482e09
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech BGCOLOR="#FFFFFF"
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech TEXT="#000000"
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech LINK="#0000FF"
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech VLINK="#000080"
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech ALINK="#FF0000"
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<!--#include virtual="header.html" -->
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr CechThis module is contained in the <CODE>mod_asis.c</CODE> file, and
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cechis compiled in by default. It provides for <CODE>.asis</CODE> files. Any
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cechdocument with mime type <CODE>httpd/send-as-is</CODE> will be processed by
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<!--%plaintext <?INDEX {\tt httpd/send-as-is} mime type> -->
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr CechTo allow file types to be defined such that Apache sends them without
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cechadding HTTP headers.<P>
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr CechThis can be used to send any kind of data from the server, including redirects
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březinaand other special HTTP responses, without requiring a cgi-script or an nph
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr CechIn the server configuration file, define a new mime type called
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<BLOCKQUOTE><CODE>AddType httpd/send-as-is asis</CODE></BLOCKQUOTE>
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březinathis defines the <CODE>.asis</CODE> file extension as being of the new
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<CODE>httpd/send-as-is</CODE> mime type. The contents of any file with a
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březina<CODE>.asis</CODE> extension will then be sent by Apache to the client with
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cechalmost no changes. Clients will need HTTP headers to be attached, so do not
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březinaforget them. A Status: header is also required; the data should be the
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech3-digit HTTP response code, followed by a textual message.<P>
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr CechHere's an example of a file whose contents are sent <EM>as is</EM> so as to
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březinatell the client that a file has redirected.
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel BřezinaStatus: 301 Now where did I leave that URL <BR>
dea636af4d1902a081ee891f1b19ee2f8729d759Pavel Březina<HTML> <BR>
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<HEAD> <BR>
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech<TITLE>Lame excuses'R'us</TITLE> <BR>
376eaf187c13c2a1eaea0ffbdd970b6b563ab74cPetr Cech</HEAD> <BR>
<!--#include virtual="footer.html" -->