You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please add the Microsoft Surface (that no one is going to buy) with for the agent = "Mozilla/4.0 (Compatible; msie 7.0; windows nt 6.2; arm; trident/6.0; touch; .net4.0e; .net4.0c; tablet PC 2.0; Version)"; // Microsoft surface.
We should be safe to add "tablet" in the agent match pattern.
I was getting a continuous redirect to my tablet_host, because you where checking the referrer to only the mobile_host. The fix was move the isUATablet test before setting the cookies/session and the change the test to
(isUAMobile && document.referrer.indexOf(mobile_host) >= 0 )
|| (isUATablet && document.referrer.indexOf(tablet_host) >= 0) || ....
Oh .. your setting either the session OR cookie variable. So the final test for the redirection should be "&& !isCookieSet && !isSessionStorage" not !(isCookieSet || isSessionStorage).
William Choy
NorthPoint Solutions
PS: Here is the patch (Sorry for the funky formatting):
Index: js/redirection-mobile.js
105a106,113
// Check if the device is a Tablet such as iPad, Samsung Tab, Motorola Xoom, Amazon Kindle or MS Surface
if (!!(agent.match(/(iPad|SCH-I800|xoom|NOOK|silk|kindle|GT-P7510|tablet)/i))) {
// Check if the redirection needs to happen for tablets
isUATablet = (config.tablet_redirection === TRUE || !!config.tablet_host) ? true : false;
isUAMobile = false;
Please add the Microsoft Surface (that no one is going to buy) with for the agent = "Mozilla/4.0 (Compatible; msie 7.0; windows nt 6.2; arm; trident/6.0; touch; .net4.0e; .net4.0c; tablet PC 2.0; Version)"; // Microsoft surface.
We should be safe to add "tablet" in the agent match pattern.
I was getting a continuous redirect to my tablet_host, because you where checking the referrer to only the mobile_host. The fix was move the isUATablet test before setting the cookies/session and the change the test to
(isUAMobile && document.referrer.indexOf(mobile_host) >= 0 )
|| (isUATablet && document.referrer.indexOf(tablet_host) >= 0) || ....
Oh .. your setting either the session OR cookie variable. So the final test for the redirection should be "&& !isCookieSet && !isSessionStorage" not !(isCookieSet || isSessionStorage).
William Choy
NorthPoint Solutions
PS: Here is the patch (Sorry for the funky formatting):
Index: js/redirection-mobile.js
105a106,113
The text was updated successfully, but these errors were encountered: