I have a site w/ a simple .htaccess rule that checks if the user is on a mobile browser and if so redirects them to our mobile site. problem is – if they decide they want to go to the regular site (and click a link that takes them there) they will eventually get back to the mobile site, b/c our .htaccess rule will catch them and redirect.
Is there an easy way, w/out modifying to much code that will allow them to “persist” on a regular site even though they have a mobile browser?
if thats not possible – is there a simple minimal solution to make this work in the code?
What I do is provide a link to the full-site on the mobile site. When the link is tapped, I set a cookie [with a very short lifetime] that lets the regular website know not to redirect.
The redirect to mobile is handled by PHP, not htaccess, on the regular site. The PHP checks for the cookie, and if not found, redirects to the mobile. The regular site also provides a link to the mobile site that destroys the cookie.