kokcito13/strah/master/www/.htaccess - Htaccess File

kokcito13/strah/master/www/.htaccess

DirectoryIndex app.php

<IfModule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/css
    AddOutputFilterByType DEFLATE text/javascript
    AddOutputFilterByType DEFLATE application/x-javascript
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE text/x-component
    AddOutputFilterByType DEFLATE text/html
    AddOutputFilterByType DEFLATE text/richtext
    AddOutputFilterByType DEFLATE image/svg+xml
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/xsd
    AddOutputFilterByType DEFLATE text/xsl
    AddOutputFilterByType DEFLATE text/xml
    AddOutputFilterByType DEFLATE image/x-icon
    AddOutputFilterByType DEFLATE application/json
</IfModule>

<IfModule mod_rewrite.c>
    RewriteEngine On

#    RewriteRule ^/company/ru/moscow/evro-polis$ http://dvestrahovki.ru/moscow/companies/evro-polis [L,R=301]
#    RewriteRule ^/vtb$ http://dvestrahovki.ru/moscow/companies/vtb [R=301,L]
#    RewriteRule ^/company/ru/moscow/ugsk$ http://dvestrahovki.ru/moscow/companies/ugsk [R=301,L]
#    RewriteRule ^/company/ru/nizhny-novgorod/ugsk$ http://dvestrahovki.ru/nizhny-novgorod/companies/ugsk [R=301,L]
#    RewriteRule ^/company/ru/rostov-na-donu/zettains$ http://dvestrahovki.ru/rostov-na-donu/companies/zettains [R=301,L]
#    RewriteRule ^/company/ru/sankt-peterburg/nig$ http://dvestrahovki.ru/sankt-peterburg/companies/nig [R=301,L]
#    RewriteRule ^/company/ru/moscow/vtb$ http://dvestrahovki.ru/moscow/companies/vtb [R=301,L]
#    RewriteRule ^/company/ru/krasnodar/gefest$ http://dvestrahovki.ru/krasnodar/companies/gefest [R=301,L]
#    RewriteRule ^/company/ru/krasnodar/zhaso$ http://dvestrahovki.ru/krasnodar/companies/zhaso [R=301,L]
#    RewriteRule ^/novosibirsk/companies/alfastrah/comments$ http://dvestrahovki.ru/krasnodar/companies/alfastrah/comments [R=301,L]
#    RewriteRule ^/moscow/companies/novosibirsk/alfastrah$ http://dvestrahovki.ru/krasnodar/companies/alfastrah [R=301,L]
#    RewriteRule ^/moscow/companies/novosibirsk/nadins$ http://dvestrahovki.ru/novosibirsk/companies/nadins [R=301,L]
#    RewriteRule ^/moscow/companies/rostov-na-donu/gefest$ http://dvestrahovki.ru/rostov-na-donu/companies/gefest [R=301,L]
#    RewriteRule ^/krasnodar/gefest$ http://dvestrahovki.ru/krasnodar/companies/gefest [R=301,L]
#    RewriteRule ^/moscow/companies/rostov-na-donu/gefest/comments$ http://dvestrahovki.ru/rostov-na-donu/companies/gefest/comments [R=301,L]
#    RewriteRule ^/moscow/companies/novosibirsk/nadins$ http://dvestrahovki.ru/novosibirsk/companies/nadins [R=301,L]
#    RewriteRule ^/moscow/companies/Novosibirsk/allianz/comments$ http://dvestrahovki.ru/novosibirsk/companies/allianz/comments [R=301,L]
#    RewriteRule ^/moscow/companies/Samara/alfastrah/comments$ http://dvestrahovki.ru/samara/companies/alfastrah/comments [R=301,L]
#    RewriteRule ^/moscow/companies/rostov-na-donu$ http://dvestrahovki.ru/rostov-na-donu/companies [R=301,L]
#    RewriteRule ^/sankt-peterburg/liberty$ http://dvestrahovki.ru/sankt-peterburg/companies/liberty [R=301,L]
#    RewriteRule ^/company/kz/astana$ http://dvestrahovki.ru [L]

    RewriteCond %{HTTP_HOST}  ^www.(.*)  [NC]
    RewriteRule ^(.*)$ http://%1/$1  [R=301,L]

    RewriteBase /
    RewriteCond %{HTTP_HOST} (.*)
    RewriteCond %{REQUEST_URI} /$ [NC]
    RewriteRule ^(.*)(/)$ $1 [L,R=301]

    RewriteCond %{REQUEST_URI}::$1 ^(/.+)/(.*)::2$
    RewriteRule ^(.*) - [E=BASE:%1]

    RewriteCond %{ENV:REDIRECT_STATUS} ^$
    RewriteRule ^app.php(/(.*)|$) %{ENV:BASE}/$2 [R=301,L]

    RewriteCond %{REQUEST_FILENAME} -f
    RewriteRule .? - [L]

    RewriteRule .? %{ENV:BASE}/app.php [L]
</IfModule>

<IfModule !mod_rewrite.c>
    <IfModule mod_alias.c>
    
        RedirectMatch 302 ^/$ /app.php/
        RedirectMatch 301 ^/company/ru/moscow/evro-polis$ http://dvestrahovki.ru/moscow/companies/evro-polis

    </IfModule>
</IfModule>

On Github License

Files

Download PDF of Htaccess file
DEFLATE, ENV, HTTP_HOST, REDIRECT_STATUS, REQUEST_FILENAME, REQUEST_URI

Comments

Apache