2 # Apache/PHP/Drupal settings.
4 # Default setup is for running drupal in vhost.
5 # You can setup drupal as alias /drupal, but you need to comment/uncomment few things.
7 # Please note that drupal-ID's don't work in subdirs, you need vhost for that.
9 <Directory /usr/share/drupal/htdocs>
10 Options FollowSymLinks
12 <IfModule mod_access.c>
17 # Set the default handler.
19 DirectoryIndex index.php
22 # Override PHP settings. More exist in sites/default/settings.php, but
23 # the following cannot be changed at runtime. The first IfModule is
24 # for Apache 1.3, the second for Apache 2.
25 # php4 module under Apache 1.3
27 php_value magic_quotes_gpc 0
28 php_value register_globals 0
29 php_value session.auto_start 0
30 php_value mbstring.http_input pass
31 php_value mbstring.http_output pass
32 php_value mbstring.encoding_translation 0
33 php_value memory_limit 12M
35 # php5 module under Apache 1.3
37 php_value magic_quotes_gpc 0
38 php_value register_globals 0
39 php_value session.auto_start 0
40 php_value mbstring.http_input pass
41 php_value mbstring.http_output pass
42 php_value mbstring.encoding_translation 0
43 php_value memory_limit 12M
46 # php under Apache 2.x module
47 <IfModule sapi_apache2.c>
48 php_value magic_quotes_gpc 0
49 php_value register_globals 0
50 php_value session.auto_start 0
51 php_value mbstring.http_input pass
52 php_value mbstring.http_output pass
53 php_value mbstring.encoding_translation 0
54 php_value memory_limit 12M
57 # Reduce the time dynamically generated pages are cache-able.
58 <IfModule mod_expires.c>
59 ExpiresByType text/html A1
62 # Various rewrite rules.
63 <IfModule mod_rewrite.c>
66 # Modify the RewriteBase if you are using Drupal in a subdirectory and
67 # the rewrite rules are not working properly.
68 # Enable RewriteBase if you have drupal configured in virtualhost root.
71 # Rewrite old-style URLs of the form 'node.php?id=x'.
72 #RewriteCond %{REQUEST_FILENAME} !-f
73 #RewriteCond %{REQUEST_FILENAME} !-d
74 #RewriteCond %{QUERY_STRING} ^id=([^&]+)$
75 #RewriteRule node.php index.php?q=node/view/%1 [L]
77 # Rewrite old-style URLs of the form 'module.php?mod=x'.
78 #RewriteCond %{REQUEST_FILENAME} !-f
79 #RewriteCond %{REQUEST_FILENAME} !-d
80 #RewriteCond %{QUERY_STRING} ^mod=([^&]+)$
81 #RewriteRule module.php index.php?q=%1 [L]
83 # Rewrite current-style URLs of the form 'index.php?q=x'.
84 RewriteCond %{REQUEST_FILENAME} !-f
85 RewriteCond %{REQUEST_FILENAME} !-d
86 RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
89 # Customized error messages.
90 ErrorDocument 404 /index.php
93 # If having drupal installed as /drupal
94 #<IfModule mod_alias.c>
95 # Alias /drupal/files /var/lib/drupal
96 # Alias /drupal /usr/share/drupal/htdocs
100 # # Customized error messages.
101 # ErrorDocument 404 /drupal/index.php
104 <Directory /var/lib/drupal>
106 SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
108 <IfModule mod_rewrite.c>
115 ServerAlias www.drupal
116 DocumentRoot /usr/share/drupal/htdocs
118 <IfModule mod_alias.c>
119 Alias /files /var/lib/drupal