htaccess detect mobile and redirection with cookie
$30 USD
Terminado
Publicado hace casi 12 años
$30 USD
Pagado a la entrega
I need a code in my htaccess that do this:
1) Detect mobile browser and redirect, like this:
if is mobile, redirect from [login to view URL] to [login to view URL]
or [login to view URL] to [login to view URL]
Always redirect to home, I don't need equivalent urls.
Actually I do this with this code:
RewriteCond %{REQUEST_URI} !^/m/.*$
RewriteCond %{HTTP_USER_AGENT} "android|blackberry|ipad|iphone|ipod|iemobile|opera mobile|palmos|webos|googlebot-mobile" [NC]
RewriteRule ^(.*)$ /m/ [L,R=302]
2) But, I also need a url that go from mobile version to normal site, and this not possible with the code that I use. Because always redirect to mobile version.
It's possible do theses two things only with htacces?
If there is other way , welcome.
.
3) Finally, you must tell me where put the code (if we use another way to htaccess). I will use code in html website and joomla website.