# This alias does not work properly with several hosts on your apache
# server Uncomment it to use it. In this case, you should also
# uncomment RewriteBase below.

#    Alias /textpattern /var/lib/textpattern

<Directory /var/lib/textpattern>

   # Comment all this if you don't want clean URL. This was previously
   # in /usr/share/textpattern/.htaccess which is now ignored because
   # you may need to change RewriteBase value.
   <IfModule mod_rewrite.c>
	RewriteEngine On
	# RewriteBase /textpattern

	RewriteCond %{REQUEST_FILENAME} -f [OR]
	RewriteCond %{REQUEST_FILENAME} -d
	RewriteRule ^(.+) - [PT,L]

	RewriteCond %{REQUEST_URI} !=/favicon.ico
	RewriteRule ^(.*) index.php

	RewriteCond %{HTTP:Authorization}  !^$
	RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
   </IfModule>

        Options +FollowSymLinks
        AllowOverride None
        order allow,deny
        allow from all
</Directory>

<Directory /var/lib/textpattern/textpattern/setup>
        order allow,deny
        allow from 127.0.0.1
</Directory>

