<IfModule mod_rewrite.c>
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^bitrix-master\.ru$ [NC]
RewriteRule ^(.*)$ https://www.sng-it.ru/$1 [L,R=301]
RewriteCond %{HTTP_HOST} ^(www\.)?bitrix-master\.ru$ [NC]
RewriteRule ^(.*)$ https://www.sng-it.ru/$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !/bitrix/urlrewrite.php$
RewriteRule ^(.*)$ /bitrix/urlrewrite.php [L]
RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
</IfModule>
Теги: редирект, 301, RewriteCond, .htaccess