You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Sandy Keathley <sk...@keathleywebs.com> on 2003/04/07 00:26:24 UTC

[users@httpd] HTML pages in CGI directories

Can someone tell me the trick to allowing HTML pages to display 
from a cgi-bin directory (a ScriptAlias directory)?

Thanks,

Sandy Keathley



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] HTML pages in CGI directories

Posted by Joshua Slive <jo...@slive.ca>.
On Sun, 6 Apr 2003, Sandy Keathley wrote:

> Can someone tell me the trick to allowing HTML pages to display
> from a cgi-bin directory (a ScriptAlias directory)?

Assuming you had
ScriptAlias /cgi-bin/ /usr/local/apache2/cgi-bin/

Remove that and replace it with
Alias /cgi-bin/ /usr/local/apache2/cgi-bin/
<Directory /usr/local/apache2/cgi-bin>
Options ExecCGI
AddHandler cgi-script cgi pl exe
</Directory>

Add whatever extensions you need to execute to the AddHandler line.  Any
file that doesn't match one of those extensions will not be executed.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org