On 18.07.06 11:48, Boyle Owen wrote:
> It is not a great idea to mix static and CGI content in the same
> directory since a simple misconfiguration can put your code on the web.

I don't think this is a problem. or, better said, such problem can appear
anywhere (e.g. just rename .php to something else)

> However, it can be done using SetHandler (see
> http://httpd.apache.org/docs/2.2/mod/core.html#sethandler) and Options
> ExecCGI.

I find AddHandler simpler and universal:

AddHandler cgi-script .cgi
Options ExecCGI

and it will work globally. If you want to enable/disable CGI's per-context,
you only need to put Options +-ExecCGI into VirtualHost/Directory/Location
secrionc.

> You also need "DirectoryIndex script.cgi" in that dir...

Or simply index.cgi and let user use proper name for the script...

(e.g. "DirectoryIndex index.var index.cgi index.html")

> You can also look at AddHandler
> (http://httpd.apache.org/docs/2.2/mod/mod_mime.html#addhandler) to
> extend CGI to all .cgi files.

I wonder why didn't you start with this ;)
-- 
Matus UHLAR - fantomas, [EMAIL PROTECTED] ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
42.7 percent of all statistics are made up on the spot. 

---------------------------------------------------------------------
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: [EMAIL PROTECTED]
   "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to