Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ru2fac/2fb511952c7d0cd3ab22082ba325905d to your computer and use it in GitHub Desktop.
Save ru2fac/2fb511952c7d0cd3ab22082ba325905d to your computer and use it in GitHub Desktop.
301 редирект со страниц со слешем на без слеша (весь сайт)
RewriteCond %{REQUEST_URI} !\?
RewriteCond %{REQUEST_URI} !\&
RewriteCond %{REQUEST_URI} !\=
RewriteCond %{REQUEST_URI} !\.
RewriteCond %{REQUEST_URI} ![^\/]$
RewriteRule ^(.*)\/$ /$1 [R=301,L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment