coar 97/04/10 20:25:06
Modified: htdocs/manual/misc FAQ.html Log: Added section on CGI usage in non-ScriptAliased directories. Submitted by: Marc Slemko Revision Changes Path 1.16 +50 -1 apache/htdocs/manual/misc/FAQ.html Index: FAQ.html =================================================================== RCS file: /export/home/cvs/apache/htdocs/manual/misc/FAQ.html,v retrieving revision 1.15 retrieving revision 1.16 diff -C3 -r1.15 -r1.16 *** FAQ.html 1997/04/09 19:23:02 1.15 --- FAQ.html 1997/04/11 03:25:04 1.16 *************** *** 8,14 **** <!--#include virtual="header.html" --> <H1>Apache Server Frequently Asked Questions</H1> <P> ! $Revision: 1.15 $ ($Date: 1997/04/09 19:23:02 $) </P> <H2>The Questions</H2> <!-- Stuff to Add: --> --- 8,14 ---- <!--#include virtual="header.html" --> <H1>Apache Server Frequently Asked Questions</H1> <P> ! $Revision: 1.16 $ ($Date: 1997/04/11 03:25:04 $) </P> <H2>The Questions</H2> <!-- Stuff to Add: --> *************** *** 23,28 **** --- 23,30 ---- <!-- - disable Apache buffering of script output by using nph- --> <!-- - access control based on DNS name really needs MAXIMUM_DNS --> <!-- and double-check that rDNS resolves to name expected --> + <!-- - add stuff about using XBitHack Full to generate a --> + <!-- Last-Modified header [section on caching SSL] --> <UL> <LI><STRONG>Background</STRONG> <OL START=1> *************** *** 57,62 **** --- 59,67 ---- <LI><A HREF="#compatible">How compatible is Apache with my existing NCSA 1.3 setup?</A> </LI> + <LI><A HREF="#CGIoutsideScriptAlias">How do I enable CGI execution + in directories other than the ScriptAlias?</A> + </LI> <LI><A HREF="#premature-script-headers">What does it mean when my CGIs fail with "Premature end of script headers"?</A> </LI> *************** *** 363,368 **** --- 368,417 ---- that fundamental feature enhancments stay consistent between the two servers for the foreseeable future. </P> + <HR> + </LI> + <LI><A + NAME="CGIoutsideScriptAlias" + ><STRONG>How do I enable CGI execution in directories other than + the ScriptAlias?</STRONG></A> + <P> + </P> + <P> + Apache recognises all files in a directory named as a + <A + HREF="../mod/mod_alias.html#scriptalias" + >ScriptAlias</A> + as being eligible for execution rather than processing as normal + documents. This applies regardless of the file name, so scripts in a + ScriptAlias directory don't need to be named + "<SAMP>*.cgi</SAMP>" or "<SAMP>*.pl</SAMP>" or + whatever. In other words, <EM>all</EM> files in a ScriptAlias + directory are scripts, as far as Apache is concerned. + </P> + <P> + To persuade Apache to execute scripts in other locations, such as in + directories where normal documents may also live, you must tell it how + to recognise them - and also that it's okey to execute them. + </P> + <OL> + <LI>In an appropriate section of your server configuration files, add + a line such as + <PRE> + <A + HREF="../mod/mod_mime.html#addhandler" + >AddHandler</A> cgi-script .cgi + </PRE> + The server will then recognise that all files in that location (and + its logical descendants) that end in "<SAMP>.cgi</SAMP>" + are script files, not documents. + </LI> + <LI>Make sure that the directory location is covered by an + <A + HREF="../mod/core.html#options" + >Options</A> + declaration that includes the <SAMP>ExecCGI</SAMP> option. + </LI> + </OL> <HR> </LI> <LI><A