Print Page | Close Window

Mobile Redirect for IPAD

Printed From: ProductCart E-Commerce Solutions
Category: ProductCart Add-on's
Forum Name: Mobile Commerce Add-on
Forum Description: Discuss issues and suggestions related to the Mobile Commece Add-on for ProductCart
URL: https://forum.productcart.com/forum_posts.asp?TID=5098
Printed Date: 25-April-2024 at 11:52pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Mobile Redirect for IPAD
Posted By: ojmuo
Subject: Mobile Redirect for IPAD
Date Posted: 13-April-2012 at 2:56pm

We would like the IPAD to redirect to the main (non-mobile) site but keep all other mobile users to redirect to the moble version. How do i modify the inc_mobiledetect.asp to keep IPAD users on the main site?




Replies:
Posted By: Greg Dinger
Date Posted: 13-April-2012 at 3:18pm

Edit the file "inc_mobiledetect.asp"

Add this code around line 44, just above "if session("pcStayNormal")="" then"

If instr(user_agent,"iPad")>0 Then
      mobile_browser=0
End If

we used this in http://www.tastefulgarden.com/store/m" rel="nofollow - www.tastefulgarden.com/store/m and it tested successfully.


-------------
GreyBeard Design Group

Certified ProductCart Developer

Web Design/Development/Hosting

http://tinyurl.com/5c8t4t" rel="nofollow - Add-Ons & Custom Code |


Posted By: ojmuo
Date Posted: 13-April-2012 at 3:59pm

Thank you.



Posted By: Greg Dinger
Date Posted: 13-April-2012 at 4:05pm
FYI, we have also created full mobile support for the SEO-friendly URL's and the content manager pages.  That code has been provided to Early Impact, and when time allows, will be distributed as part of the base application.  Not sure about their schedule.
 
We don't have this bundled in a form that I can just send out, but if you need it, it could be installed for you. 


-------------
GreyBeard Design Group

Certified ProductCart Developer

Web Design/Development/Hosting

http://tinyurl.com/5c8t4t" rel="nofollow - Add-Ons & Custom Code |


Posted By: rocky123
Date Posted: 30-July-2012 at 5:29am
The screen width for the iPhone is 480, Blackberry is 480, Samsung Galaxy listed as 480, I couldn't find the actual reported screen width for the Galaxy S3 but since it is 4.8" which is substantially less than the 7" tablet that reports a screen width of 600 I think it's a pretty sure bet that it reports less than 600.
There is general confusion in mobile devices regarding screen Resolution and reported screen width by the browser, they are two different specifications and relate loosely by how many ppi the display is capable of showing in the actual width of the display.

-------------
rocky


Posted By: macleather
Date Posted: 30-July-2012 at 8:31pm
Hey Greg,

I can't find the line "if session("pcStayNormal")="" then" anywhere in the file. I'm on version v.4.1b SP 2, could that be the reason? Our current re-direction works fine but we also have the iPad issue. 

Alan


-------------
Alan
http://www.mcpcustomleather.com - MacPherson Custom Leather


Posted By: Greg Dinger
Date Posted: 30-July-2012 at 8:35pm
I have this in tastefulgarden.com
 
If InStr(Request.ServerVariables("HTTP_USER_AGENT"), "Novarra") > 0 Then mobile_browser = mobile_browser+1
'TEST MODE
'mobile_browser=1
If instr(user_agent,"iPad")>0 Then  'gbdg per Matt @ EI 3/12/2012
 mobile_browser=0     'gbdg per Matt @ EI 3/12/2012
End If         'gbdg per Matt @ EI 3/12/2012


-------------
GreyBeard Design Group

Certified ProductCart Developer

Web Design/Development/Hosting

http://tinyurl.com/5c8t4t" rel="nofollow - Add-Ons & Custom Code |



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net