Routing mobile users to a dedicated mobile site


(Tanuj) #1

Is there a way to route users visiting from a mobile to tablet to a dedicated website for mobile, like “m.site.com”?

The reason I’m asking for this over “Layouts” is because a lot of my users have a 1280x1024px resolution, and this clashes with my iPad layout, which features a Menu bar unlike the Navigation bar for desktop users.

Any help would be greatly appreciated!


(Hans-Gerd Claßen) #2

guess, this is most used detectmobilebrowser.com

within hype (43.9 KB)


(Tanuj) #3

Thanks for the help Hans, but how can I redirect my users to the mobile site after recognizing their device?


(Hans-Gerd Claßen) #4

it returns true if mobile…
true = redirect :stuck_out_tongue_winking_eye:


(Tanuj) #5

Sorry, I have no clue about JS.

Do I add that line at end of the same javascript used to recognise the device?


(Hans-Gerd Claßen) #6

then it’s time to start :slight_smile: now …
javascript, html, css, php … nothing is better documentated within the www!

sthg. like

if(jQuery.browser.mobile) window.open("www.youraddress.com","_self");

(Tanuj) #7

Haha, I have started. Albeit very selectively.

Thanks for all you help Hans!