Answer the question
In order to leave comments, you need to log in
.htaccess redirect, google insights?
Greetings toasters, please help me figure out .htaccess, the fact is that I made a mobile version of the site, but that's a problem, the site is static. A few questions:
1. Main site file:
RewriteEngine on
RewriteCond %{HTTP_USER_AGENT} (?i:midp|samsung|nokia|j2me|avant|docomo|novarra|palmos|palmsource|opwv|chtml|pda|mmp|blackberry|mib|symbian|wireless|nokia|hand|mobi|phone|cdm|upb|audio|SIE|SEC|samsung|HTC|mot-|mitsu|sagem|sony|alcatel|lg|eric|vx|NEC|philips|mmm|xx|panasonic|sharp|wap|sch|rover|pocket|benq|java|pt|pg|vox|amoi|bird|compal|kg|voda|sany|kdd|dbt|sendo|sgh|gradi|jb|dddi|moto|iphone|android)
RewriteRule ^.*$ https://сайт.ру/mobile [R=301,L]
RewriteCond %{HTTP_HOST} !^сайт.ру$
RewriteRule ^(.*) https://сайт.ру/$1 [R=301,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule ^index\.php$ https://сайт.ру/ [R=301,L]
ErrorDocument 404 https://сайт.ру/404.htm
RewriteEngine on
RewriteCond %{HTTP_HOST} !^сайт.ру$
RewriteRule ^(.*) https://сайт.ру/$1 [R=301,L]
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
RewriteRule ^index\.php$ https://сайт.ру/ [R=301,L]
ErrorDocument 404 https://сайт.ру/404.htm
Не используйте переадресацию с целевой страницы на следующие URL:[LIST]
[*]https://сайт.ру/
[*]https://сайт.ру/mobile
[*]http://сайт.ру/mobile/
[*]https://сайт.ру/mobile/
[/LIST]
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question