• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Need code to direct Android users to our mobile site

anonywebd

Lurker
Does anyone know of a code that will specifically direct android users to a mobile website? I have scoured the internet and have iPhone redirecting, but I cannot find a code that works on the android. Thanks for the help.
 
Hi, welcome to the forums! Are you referring to redirecting to a mobile site as opposed to the desktop version of a site?
 
Yes exactly. We have been able to redirect on the iPHone, but I have scoured the internet and none of the codes I have found are working for Android.
 
In that case, you may want to look into something that would detect the user agent string of the user's browser and choose based on that which to go to. Personally, I'm not a web developer but just a bit of googling found me that much.
 
Yea I did that. I have searched google up and down and all around. lol. I have tried every code I could find. Still none of them are working. I lost a job because it wouldn't work. Stinks. After I built a mobile site for them and was able to redirect to iPhone, but because I couldn't get Android, I lost it. What a waste. Oh well. Thanks for at least trying to help. :)
 
I'm not a corder. I think responsive themes are better option. It fit with screen resolution.
 
Back
Top Bottom