Answer the question
In order to leave comments, you need to log in
How to redirect from slash to without slash the entire site?
I try like this:
RewriteCond %{REQUEST_URI} !\?
RewriteCond %{REQUEST_URI} !\&
RewriteCond %{REQUEST_URI} !\=
RewriteCond %{REQUEST_URI} !\.
RewriteCond %{REQUEST_URI} ![^\/]$
RewriteRule ^(.*)\/$ /$1 [R=301,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php
Site.ru redirected too many times.
Delete cookies..
ERR_TOO_MANY_REDIRECTS
RewriteCond %{REQUEST_URI} !\?
RewriteCond %{REQUEST_URI} !\&
RewriteCond %{REQUEST_URI} !\=
RewriteCond %{REQUEST_URI} !\.
RewriteCond %{REQUEST_URI} !\/$
RewriteRule ^(.*[^\/])$ /$1/ [R=301,L]
Answer the question
In order to leave comments, you need to log in
created a physical folder, placed index.php in it - a cyclic redirect comes out
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)/$ /$1 [R=301,L]
DirectorySlash Off
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question