Hello. I came across a sample JS for redirecting mobile traffic from a main site to a mobile site in the “snippets” section of this site so I thought I’d ask my question here. I’m trying to implement the code, or a modification of it and can’t seem to get it working.
Here are 2 things I’ve tried based on what I’ve found. I want to redirect the traffic but if the users click a link to go back to the main site, from the mobile site, I need them to not get stuck in a loop. Neither of these actually sent the mobile traffic over period so i’m unsure if method to stop the loop works.
also tried this,
Anyone have any insight? Thanks!