hello,
i have an issue with the htaccess. Installed on a subdir of my website.
the dir is: http://pigmotel.com/rooms/
the htaccess works ONLY if I type the address EXACTLY as written above.
IF I remove the trailing slash or I try to put a "www" and remove the trailing slash, it redirects to the main index of the website.
could you help me and tell me what is wrong with it?
Code:
RewriteEngine On
RewriteBase /rooms/
# Rewrite http://www.domain.com to domain.com
RewriteCond %{HTTP_HOST} ^www.(.*)
RewriteRule ^(.*) http://%1/$1 [R,L]
#uploaded files
RewriteRule ^(.*)?/?files/(.*) wp-content/blogs.php?file=$2 [L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule . - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-.*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*.php)$ $2 [L]
RewriteRule . index.php [L]
Thank you very much.
Simon
p.s. when you try it w/out trail slash it will redirect you to the main public_html wich has another redirect to the "/it" dir. That is correct. Thank you.