# Configuration for the apache web server -*- apache -*-
# inspired by /etc/phpldapadmin/apache.conf from the Debian package of
# phpldapadmin (version 0.9.4-10) maintained by Fabio Tranchitella
# <kobold@kobold.it>
# improved through advanced.htaccess from Michael Stucki <mundaun@gmx.ch>
# Define the package aliases. The following directive defines the
# /TYPO3root as /typo3. If this is changed, search for
# TYPO3root and adapt the found directives appropriate.
<IfModule mod_alias.c>
Alias /typo3 /var/lib/typo3-dummy
#Alias /typo3-dummy /var/lib/typo3-dummy
</IfModule>
# To use TYPO3 as a VirtualHost, comment out and customize the following section
# <VirtualHost *:*>
# ServerName typo3.example.com
# ServerAdmin webmaster@example.com
# DocumentRoot /var/lib/typo3-dummy
# ErrorLog logs/typo3.example.com-error.log
# CustomLog logs/typo3.example.com-access.log combined
# </VirtualHost>
<DirectoryMatch /var/lib/typo3-dummy/>
DirectoryIndex index.php index.html
# TYPO3 needs files shared between different instances. These are
# symlinked into the document root directory. The following
# directive enables that apache follows the symlinks.
Options +FollowSymLinks
# disable .htaccess, because it slows down apache
AllowOverride ALL
Order allow,deny
Allow from all
### Begin: PHP optimisation ###
<IfModule mod_mime.c>
<IfModule mod_php4.c>
# enable PHP processing for files ending with .php
AddType application/x-httpd-php .php
# enable safe PHP operation
php_admin_value safe_mode on
php_admin_value safe_mode_include_dir /usr/share/typo3/typo3_src-4.0/
# Maximum allowed size for uploaded files (PHP defaults to 2MB)
php_admin_value upload_max_filesize 10M
# Maximum amount of memory a script may consume (PHP defaults to 8MB)
php_admin_value memory_limit 16M
# list of directories where require(), include() and fopen_with_path() look for files
php_admin_value include_path /var/lib/typo3-dummy/:/usr/share/typo3/typo3_src-4.0/:.
# Limit the files that can be opened by PHP to the specified directory-tree(s)
php_admin_value open_basedir /var/lib/typo3-dummy/:/usr/share/typo3/:/usr/share/typo3-dummy/:/etc/typo3-dum
# in safe mode programs that are not in this directory will not be started
php_admin_value safe_mode_exec_dir /var/lib/typo3-dummy/execdir/
# The PHP developers recommend disabling this feature. Do that.
# It's deprecated and is likely to be unsupported in future
# versions of PHP.
php_flag allow_call_time_pass_reference off
# TYPO3 works fine with register_globals turned off.
# This is highly recommended!
php_flag register_globals off
# PHP may not declare the argv & argc variables (that would
# contain the GET information).
# TYPO3 doesn't need this, so just turn it off.
php_flag register_argc_argv off
# Magic quotes for runtime-generated data (data from SQL, exec(), etc.)
php_flag magic_quotes_gpc off
# Order in which PHP registers GET, POST, Cookie and Built-in variables
php_value variables_order GPCS
</IfModule>
</IfModule>
### End: PHP optimisation ###
### Begin: Rewrite stuff ###
# <IfModule mod_rewrite.c>
#
# # Enable URL rewriting
# RewriteEngine On
#
# # To assist in debugging rewriting, you could use these lines
# # DON'T enable it for production!
# # This will only work in httpd.conf, not in .htaccess files
# #RewriteLog /var/log/apache/rewrite.log
# #RewriteLogLevel 9
#
# # If you use the RealUrl extension, then you'll have to enable the next line.
# # You will have to change this path if your TYPO3 installation is located
# # in a subdirectory of the website root.
# #
# # If you place this in httpd.conf, you cannot use this directive in any case!
# #RewriteBase /
#
# # Stop rewrite processing if we are in the typo3/ directory
# # For httpd.conf, use this line instead of the next one:
# # RewriteRule ^/TYPO3root/(typo3|typo3temp|typo3conf|t3lib|tslib|fileadmin|uploads|showpic\.php)/ - [L]
# # RewriteRule ^(typo3|typo3temp|typo3conf|t3lib|tslib|fileadmin|uploads|showpic\.php)/ - [L]
# RewriteRule ^/typo3/(typo3|typo3temp|typo3conf|t3lib|tslib|fileadmin|uploads|showpic\.php)/ - [L]
# #RewriteRule ^/typo3-dummy/(typo3|typo3temp|typo3conf|t3lib|tslib|fileadmin|uploads|showpic\.php)/ - [L]
#
# # Redirect http://mysite/typo3 to http://mysite/typo3/index_re.php
# # and stop the rewrite processing
# # For httpd.conf, use this line instead of the next one:
# # RewriteRule ^/TYPO3root/typo3$ /TYPO3root/typo3/index.php [L]
# # RewriteRule ^typo3$ typo3/index_re.php [L]
# RewriteRule ^/typo3/typo3$ /typo3/typo3/index.php [L]
# #RewriteRule ^/typo3-dummy/typo3$ /typo3-dummy/typo3/index.php [L]
#
# # If the file/symlink/directory does not exist => Redirect to index.php
# # Important note: If you copy/paste this into httpd.conf instead
# # of .htaccess you will need to add '%{DOCUMENT_ROOT}' left to each
# # '%{REQUEST_FILENAME}' part.
# RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
# RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-d
# RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-l
#
# # Main URL rewriting.
#
# # If you use Windows and SimulateStaticDocuments do not work, try adding a
# # slash (/) right before 'index.php' below.
#
# # The example shows how to rewrite only *.html and *.pdf files to index.php
# # This may be helpful when using an extension that can generate PDF files
# # on the fly.
# # Example: RewriteRule .*\.(html|pdf)$ index.php [L]
#
# # For httpd.conf, use this line instead of the next one that has no '#':
# # RewriteRule .* /TYPO3root/index.php [L]
#
# # For use with the RealUrl extension, you might need to remove the
# # RewriteBase directive somewhere above and use this line instead of the
# # next one:
# # RewriteRule .* /index.php [L]
# # RewriteRule .* index.php [L]
# RewriteRule .* /typo3/index.php [L]
# #RewriteRule .* /typo3-dummy/index.php [L]
#
# ### End: Rewrite stuff ###
# </IfModule>
#
</DirectoryMatch>