Answer the question
In order to leave comments, you need to log in
Redirecting to the mobile version from all pages of the site?
Hello! You need a normal redirect from the main to the mobile version of the site when using a mobile device. I'm not kidding myself.
Found on the Internet
RewriteEngine On
RewriteCond %{HTTP_ACCEPT} "text/vnd.wap.wml¦application/vnd.wap.xhtml+xml" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "acs|alav|alca|amoi|audi|aste|benq|blac|blaz|brew|cell|cldc|cmd-" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "dang|doco|erics|hipt|inno|ipaq|java|jigs|kddi|keji|leno|lg-c|lg-d|lg-g|lge-" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "maui|maxo|midp|mits|mmef|mobi|mot-|moto|mwbp|nec-|newt|noki|opwv" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "palm|pana|pant|pdxg|phil|pluc|port|prox|qtek|qwap|sage|sams|sany" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "sch-|sec-|send|seri|sgh-|shar|sie-|siem|smal|smar|sony|sph-|symb|t-mo" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "teli|tim-|tsm-|upg1|upsi|vk-v|voda|w3cs|wap-|wapa|wapi" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "wapp|wapr|webc|winw|winw|xda|xda-" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "up.browser|up.link|windowssce|iemobile|mini|mmp" [NC,OR]
RewriteCond %{HTTP_USER_AGENT} "symbian|midp|wap|phone|pocket|android|mobile|pda|psp" [NC]
RewriteRule ^(.*)$ http://m.stroyartel-kazan.ru/$1 [NC,L]
Answer the question
In order to leave comments, you need to log in
If the site is in php, then it seems to me that mobiledetect.net would be better
Even with a good Internet connection, the pictures are barely loading on your site.
1. I would like your disco to be cut off ;(
2. you also have a reverse redirect to a non-mobile one, can you show the entire .htaccess.
3. have you tried to typeset on bootstrap?
4. RewriteRule ^(.*)$ m.stroyartel-kazan.ru/$1 [NC,L] - clearly says that with logic all the rules and problems are not in this rule.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question