Closed (duplicate)
Project:
Mobile Tools
Version:
6.x-2.1
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Reporter:
Created:
23 Jan 2011 at 08:19 UTC
Updated:
29 May 2012 at 18:25 UTC
Hi-
I'm requiring my site to use theme switching based on device detection. Site looks great on the laptop, but I've created a mobile theme for the iPhone and iPad. When I choose a theme for the iPhone, it changes to whatever I select. The iPad continues to display the main theme even when the filter is enabled and the mobile theme is selected.
Comments
Comment #1
Chris Vanderwall commentedbump
Comment #2
mikebann commentedTry turning cache off. Especially if you are not redirecting different devices to different url's. I think this module has to be revamped to recognize how drupal cache's things.
Comment #3
Chris Vanderwall commentedUnfortunately, that was already the case. I'm working on a development site, so already had the cache turned off. Any other ideas?
Comment #4
joshberry commentedOk, so on line 497 of mobile_tools.module, the iPad case is treating the browser as a desktop browser:
Change 'desktop' to 'mobile' and you should be all set:
Comment #5
twom commentedHi,
By design Mobile Tools treats iPads as desktop devices. It is really a matter of preference for your specific project what determines what you need.
The best solution is to write your own custom device detection plugin to Mobile Tools where you do whatever you want:
http://mobiledrupal.com/content/create-your-own-device-detection-algorit...
Comment #6
Gastonia commentedI'm having this problem as well.
But, the problem is related to the new iPad software update that happened just a couple weeks ago to 4.3. After this update, the os and browser agent strings changed, and mobile tools is no longer correctly recognizing the device.
True that mobile tools by design treats iPad as a Desktop version. But this isn't the case if you select the filter for iPad and manually assign it another theme.
Mine was working perfectly, and then suddenly it broke right after the update.
So, in other words, as soon as mobile tools is updated to correctly detect iPad as of 4.3, it should work fine after that.
Comment #8
bkosborneHmmm hopefully this gets fixed. I'll try and get a patch up if I have time.
Comment #9
devin carlson commentedThis is a duplicate of #1509808: Administrative UI for managing device groups.