Alister West

home is where your code is ...

Apache Directives (location, directory, files, etc..)

with mod_perl + cgi-bin

# I am running mod_perl under /. I also want /cgi-bin/ to work.
# When combining Location blocks make sure 'cgi-bin' block follows root block.
# Apache 2.2

<Location />
    Order allow,deny
    Allow from all
    SetHandler modperl
    PerlResponseHandler Plack::Handler::Apache2
    PerlSetVar psgi_app /var/home/alister/

# Tell Location block where cgi's are
Alias /cgi-bin/ /var/home/alister/

# This block *must* follow / in order to merge correctly 
<Location /cgi-bin/>
    Options +ExecCGI
    SetHandler cgi-script

# Run PHP via mod-php instead of cgi
LoadModule php5_module /usr/lib/apache2/modules/
AddType application/x-httpd-php .php
<Location /cgi-bin/*.php>
    SetHandler application/x-httpd-php
By Alister West