Options -Indexes
# For security reasons, Option followsymlinks cannot be overridden.
# Options +FollowSymLinks
Options +SymLinksIfOwnerMatch
DirectoryIndex index.php index.html
ErrorDocument 404 /404.php
AddDefaultCharset utf-8
RewriteEngine on
RewriteBase /
# Редирект со старых адресов
RewriteRule ^garanty/ /redirect/ [L,R=301]
RewriteRule ^shop/замки-и-фурнитура/ /redirect/ [L,R=301]
# расcкомментируйте строки ниже, если хотите чтобы сайт был всегда с www,
# т.е. постоянный редирект с http://site.ru/ на http://www.site.ru/
# RewriteCond %{HTTP_HOST} !^www.
# RewriteRule (.*) http://www.%{HTTP_HOST}/$1 [R=301,L]
RewriteRule ^(.*)sitemap.xml$ index.php?rewrite=sitemap.xml [QSA]
RewriteRule ^(&*)(.*)/$ index.php?rewrite=$2 [QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(&*)(.*)$ index.php?rewrite=$2 [QSA]
RewriteRule ^index.php\/(.*)$ index.php?rewrite=index.php/$1 [QSA]
# If-Modified-Since (if php is not installed as cgi then comment lines below)
RewriteRule .* - [E=HTTP_IF_MODIFIED_SINCE:%{HTTP:If-Modified-Since}]
RewriteRule .* - [E=HTTP_IF_NONE_MATCH:%{HTTP:If-None-Match}]
Header append Cache-Control "no-store, no-cache, must-revalidate"