2 Replies - 3587 Views - Last Post: 13 April 2013 - 09:39 AM

#1 solwebsolutions  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 10-April 13

Mobile Redirect from specific page / QR Code

Posted 10 April 2013 - 07:14 PM

My client has created a QR Code that goes to a specific page on her non-mobile site. She does have a mobile site, m.customersdomain.com

Question is, the QR Code has already been submitted to print for advertising and is going to a regular URL like: http://www.customerd...om/specificpage

Is there a way to look for mobile devices that hit this one non-mobile page and redirect them to a mobile URL / page with the same content?

Is This A Good Question/Topic? 0
  • +

Replies To: Mobile Redirect from specific page / QR Code

#2 BetaWar  Icon User is offline

  • #include "soul.h"
  • member icon

Reputation: 1183
  • View blog
  • Posts: 7,254
  • Joined: 07-September 06

Re: Mobile Redirect from specific page / QR Code

Posted 10 April 2013 - 07:54 PM

Yes, through any server-side programming language you should be able to take a look at the user-agent header that is being sent along with any and all HTTP requests. If it is a mobile device you know that it is safe to redirect them to the mobile version of the site. There is even a website out there devoted to mobile redirects that has a simple to use PHP class you can get: http://mobiledetect.net/

Hope that helps.
Was This Post Helpful? 0
  • +
  • -

#3 solwebsolutions  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 10-April 13

Re: Mobile Redirect from specific page / QR Code

Posted 13 April 2013 - 09:39 AM

BetaWar,

Have this so far for JS:

if ((screen.width <= 700) &&
currentpage("regularURL")) {
window.location = "mobileurl";
}

I just need to figure out how to look @ the current URL, and if it is in fact regular URL, then send them via window.location to mobile URL
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1