Ok there is the case
one virtual host domain1.com
with domain aliases domain2.com
document root for that virtual host is /var/www/html
inside /var/www/html i make folder domain2
i wont when someone time domain2.com in the folder to make a redirect inside domain2 folder
here is what rules i have
RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?domain2.com*
RewriteCond %{REQUEST_URI} !/domain2/
RewriteRule (.*) /domain2/$1
and that works perfect except wehn you try to access folders inside domain2
for example
If i write n browser http://www.domain2.com/test/
everything is just fine
but if i write in browser http://www.domain2.com/test (without slash at the end )
that redirect me to http://www.domain2.com/domain2/test/
Any ideas how i can fix that ?