Closed Bug 1033886 Opened 11 years ago Closed 10 years ago

RottenTomatoes.com doesn't server mobile content to Firefox OS

Categories

(Web Compatibility :: Site Reports, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: karlcow, Assigned: karlcow)

References

()

Details

(Whiteboard: [country-us][clientsniff][sitewait])

+++ This bug was initially created as a clone of Bug #950170 +++ With Firefox OS on a Flame device. Go to http://www.rottentomatoes.com/ Expected: Receive the mobile site like Firefox on Android. aka http://www.rottentomatoes.com/mobile/ Actual: Receiving the desktop site.
This site intends to send mobile browsers to a mobile site, but there is a mistake in the code intended to handle the redirect. Hence the browser on Firefox OS phones get desktop content instead of mobile. There is client-side browser detection in these files: <script src="http://d1rjibvava1hwe.cloudfront.net/static/js/lib/device.min.js"></script> <script src="http://d1rjibvava1hwe.cloudfront.net/static/js/mobile.upsell.redirect.js"></script> Examples of the JavaScript logic: /***** START of mobile upsell-redirect flow ******/ if(device.tablet()){ if(!getParameterByName("nopopup") && !hasSeenUpsell()){ setCookie(UPSELL_COOKIE, "true", UPSELL_COOKIE_EXPIRE_DAYS, "/"); showUpsell(); } // Else continue to desktop page (no-op) } else if(device.mobile()){ if(!getParameterByName("nopopup") && !hasSeenUpsell()){ setCookie(UPSELL_COOKIE, "true", UPSELL_COOKIE_EXPIRE_DAYS, "/"); showUpsell(); } if(!getParameterByName("fullsite")){ if(!hasFullSitePermCookie()){ redirectToMobileWeb(); } else { if(!hasRevertPromptCookie()){ promptRevertToMobileWeb(); } } } } In this code, hasSeenUpsell() tries to call getCookie() - this error is thrown: ReferenceError: getCookie is not defined No mobile browsers are currently redirected to the mobile site due to the missing function definition.
Whiteboard: [country-us] → [country-us][clientsniff][contactready]
The site needs to make sure getCookie() is defined before this code runs.
Whiteboard: [country-us][clientsniff][contactready] → [country-us][clientsniff][sitewait]
Assignee: nobody → kdubost
Status: NEW → ASSIGNED
This has been fixed. Yeah \o/
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Product: Tech Evangelism → Web Compatibility
Component: Mobile → Site Reports
You need to log in before you can comment on or make changes to this bug.