I hope this is the right place to post this...
I was wondering if anyone can give me an opinion on the best way to redirect a site to another url when a mobile phone opens the page.
Since I'm using wordpress, my first thought was to create a page with a domain http://www.example.com/mobile and assign a page template to it, and write a small function in the function.php to redirect using $_SERVER['HTTP_USER_AGENT']. I would rather have the domain as something like m.example.com by using sub domains but I don't think that would work with permalinks, if it can be done with permalinks, please tell me. If there's a better way to do this, I would also love to know.
Any tips/links for tutorials/suggestions anyone can give me will be greatly appreciated.
Thanks
-Charles
PS: I'm using jquery mobile framework for the mobile version of the site.