phphttp-redirectmobile

How to redirect from mobile web site to full site?


I was trying to figure out how to redirect from my mobile web site to full site. When I create a button e.g.: "View Full Site" - it did not go to the full site, instead it go back to mobile web site. I use Google Code: http://code.google.com/p/phpmobilizer/ to convert from normal web site to mobile site. I was wondering if you know some php code that can redirect from mobile site to full site?


Solution

  • The problem you're facing is that you're being redirect back to your mobile domain again as soon as you're on your main domain with your mobile device.

    You could try something like the following:

    If the user wants to access the normal version, set a session variable and redirect him to the normal domain. On the normal domain, only execute the phpmobilizer as long as the session var for only accessing the normal domain hasn't been set.