Hi! I have the following .htaccess in my subdomain... RewriteEngine On RewriteCond %{HTTP_HOST} !^xxx\.xxx\.com$ [NC] RewriteCond %{HTTP_HOST} !^$ RewriteCond %{REQUEST_URI} ^/content($|/.*$) RewriteRule ^.* http://xxx.xxx.com%1 [R=301,L] RewriteBase / RewriteRule ^tag/(.*)$ tag/$1/ [R=301,L] RewriteRule ^tag/(.*)/$ template.php?name=$1 [L] RewriteRule ^feed/(.*)$ include/grouper/rsscache/$1.xml [L] Code (markup): I want to add the trailing slash automatically (RewriteRule ^tag/(.*)$ tag/$1/ [R=301,L]) to all the urls, but when an url is requested such as /tag/Nintendo It enters an endless loop that adds slashes at the end of my site and ends up like this -> /tag/Nintendo//////////////////////// How can I fix this? Thanks in advanced! Also, how can I 301 all address with whitespace (%20) like /tag/Taylor%20Hicks to /tag/Taylor_Hicks, just like wikipedia when you type en.wikipedia.org/wiki/Taylor Hicks it redirects to en.wikipedia.org/Taylor_Hicks Thanks again guys!
For geting %20 changed to _ editing the script is the easiest way unless RewriteRule ^([^.]+) ([^.]+)$ http://www.domain.com/$1_$2 [R=301,L] does it.