mod_actions.html revision 9f0c715c7f536475c80dc07f02cf4147768cc4a8
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding<!-- Background white, links blue (unvisited), navy (visited), red (active) -->
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding BGCOLOR="#FFFFFF"
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding TEXT="#000000"
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding LINK="#0000FF"
db479b48bd4d75423ed4a45e15b75089d1a8ad72fielding VLINK="#000080"
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd ALINK="#FF0000"
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdnd<!--#include virtual="header.html" -->
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdndThis module is contained in the <CODE>mod_actions.c</CODE> file, and
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdndis compiled in by default. It provides for
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdndexecuting CGI scripts based on media type or request method. It is not
d5d794fc2f4cc9ca6d6da17cfa2cdcd8d244bacdndpresent in versions prior to Apache 1.1.
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveThis module lets you run CGI scripts whenever a file of a certain type
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveis requested. This makes it much easier to execute scripts that
80c4526970a11f37c0f8e3b82afdf03902dac3f3sliveprocess files.
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalic><STRONG>Syntax:</STRONG></A> Action <EM>action-type cgi-script</EM><BR>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe><STRONG>Context:</STRONG></A> server config, virtual host, directory,
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe .htaccess<BR>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe HREF="directive-dict.html#Override"
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna HREF="directive-dict.html#Compatibility"
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna><STRONG>Compatibility:</STRONG></A> Action is only available in Apache 1.1
031bbbc0d1189b07330e38d0c126820a9ab7795egryzorThis directive adds an action, which will activate <EM>cgi-script</EM> when
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<EM>action-type</EM> is triggered by the request. The <EM>action-type</EM> can
031bbbc0d1189b07330e38d0c126820a9ab7795egryzorbe either a <A HREF="/handler.html">handler</A> or a MIME content type. It
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquernasends the URL and file path of the requested document using the standard CGI
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquernaPATH_INFO and PATH_TRANSLATED environment variables.
031bbbc0d1189b07330e38d0c126820a9ab7795egryzor><STRONG>Syntax:</STRONG></A> Script <EM>method cgi-script</EM><BR>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna><STRONG>Context:</STRONG></A> server config, virtual host, directory<BR>
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe HREF="directive-dict.html#Compatibility"
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe><STRONG>Compatibility:</STRONG></A> Script is only available in Apache 1.1
5ae609a8a09239d20f48a4a95c4f21b713995babwroweand later; arbitrary method use is only available with 1.3.10 and later
5ae609a8a09239d20f48a4a95c4f21b713995babwroweThis directive adds an action, which will activate <i>cgi-script</i> when
5ae609a8a09239d20f48a4a95c4f21b713995babwrowea file is requested using the method of <i>method</i>. It sends the
e4e60c2f7ba8f12b687f588b89e413842e9f2d76igalicURL and file path of the requested document using the standard
5ae609a8a09239d20f48a4a95c4f21b713995babwroweCGI PATH_INFO and PATH_TRANSLATED environment variables.
5ae609a8a09239d20f48a4a95c4f21b713995babwrowe<blockquote>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquernaone of <code>GET</code>, <code>POST</code>, <code>PUT</code>, or
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<code>DELETE</code>. As of 1.3.10, any arbitrary method name
9f19223e8fb7b99f5f1cc02c8c3c2c6567793262rbowenmay be used. <b>Method names are case-sensitive</b>, so
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquerna<code>Script PUT</code> and <code>Script put</code>
7e8f5c6496b3825b6b128e2aacc4b1b09d28553dpquernahave two entirely different effects.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive</blockquote>
313bb560bc5c323cfd40c9cad7335b4b8e060aedkessNote that the Script command defines default actions only. If a CGI
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivescript is called, or some other resource that is capable of handling
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivethe requested method internally, it will do so. Also note that Script
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivewith a method of <CODE>GET</CODE> will only be called if there are
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivequery arguments present (<EM>e.g.</EM>, foo.html?hi). Otherwise, the request
80c4526970a11f37c0f8e3b82afdf03902dac3f3slivewill proceed normally.
80c4526970a11f37c0f8e3b82afdf03902dac3f3slive Script GET /cgi-bin/search #<EM>e.g.</EM> for <ISINDEX>-style searching
fb77c505254b6e9c925e23e734463e87574f8f40kess<!--#include virtual="footer.html" -->