Saturday, June 26, 2010

Apache Directives

Note to self (.htaccess):

To set 403 Forbidden access
Order Deny,Allow
Deny from all

To enable CGI scripts
Options +ExecCGI
AddHandler cgi-script cgi pl

And remember to chmod 777
if you want mkdir permissions

To add type
AddType application/xhtml+xml .xhtml

File specific
<files somefile.txt>
# your stuff here

Directory specific
<Directory /some/path/>
# your stuff here

List Directory
Options +Indexes

PHP specific
php_flag display_errors on
php_value memory_limit 12M