mirror of
https://github.com/apache/httpd.git
synced 2026-01-06 09:01:14 +03:00
Add example and comments when using ScriptAlias with a file.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@705117 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -379,6 +379,18 @@ target as a CGI script</td></tr>
|
||||
</Location>
|
||||
</code></p></div>
|
||||
|
||||
<p><code class="directive">ScriptAlias</code> can also be used in conjunction with
|
||||
a script or handler you have. For example:</p>
|
||||
|
||||
<div class="example"><p><code>
|
||||
ScriptAlias /cgi-bin/ /web/cgi-handler.pl
|
||||
</code></p></div>
|
||||
|
||||
<p>In this scenario all files requested in <code>/cgi-bin/</code> will be
|
||||
handled by the file you have configured, this allows you to use your own custom
|
||||
handler. You may want to use this as a wrapper for CGI so that you can add
|
||||
content, or some other bespoke action.</p>
|
||||
|
||||
<div class="warning">It is safer to avoid placing CGI scripts under the
|
||||
<code class="directive"><a href="../mod/core.html#documentroot">DocumentRoot</a></code> in order to
|
||||
avoid accidentally revealing their source code if the
|
||||
|
||||
@@ -373,6 +373,18 @@ target as a CGI script</description>
|
||||
</Location>
|
||||
</example>
|
||||
|
||||
<p><directive>ScriptAlias</directive> can also be used in conjunction with
|
||||
a script or handler you have. For example:</p>
|
||||
|
||||
<example>
|
||||
ScriptAlias /cgi-bin/ /web/cgi-handler.pl
|
||||
</example>
|
||||
|
||||
<p>In this scenario all files requested in <code>/cgi-bin/</code> will be
|
||||
handled by the file you have configured, this allows you to use your own custom
|
||||
handler. You may want to use this as a wrapper for CGI so that you can add
|
||||
content, or some other bespoke action.</p>
|
||||
|
||||
<note type="warning">It is safer to avoid placing CGI scripts under the
|
||||
<directive module="core">DocumentRoot</directive> in order to
|
||||
avoid accidentally revealing their source code if the
|
||||
|
||||
Reference in New Issue
Block a user