Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mobile theme profiles #18

Open
sminnee opened this issue Mar 31, 2012 · 2 comments
Open

Mobile theme profiles #18

sminnee opened this issue Mar 31, 2012 · 2 comments

Comments

@sminnee
Copy link
Member

sminnee commented Mar 31, 2012

From http://open.silverstripe.org/ticket/6008

Allow for a ComplexTableField? so people can define which devices should receive a mobile theme. This would mean you can define a number of different themes for different devices.

For example:

Opera mobile, iPhone goes to "mymobiletheme" iPad and Dell Streak go to "mytablettheme"

Any mobile devices that don't belong in a profile would go to full site.

We should also allow an easy way for site developers to set their own mobile devices in the profile checkbox lists, as the default ones won't cover all mobiles by far.

We could also allow for all non-popular mobiles to go to another theme (or an existing one), so there's a fallback for old Nokia phones, for example.

@nedmas
Copy link

nedmas commented Dec 19, 2012

So for a recent client project I needed to be able to config which devices displayed a mobile site and which didn't. My solution was to switch out the current device detection and replace it with Mobile_Detect (https://github.com/serbanghita/Mobile-Detect) and let the user set which rules to use when checking if a device is a mobile.

I know it doesn't provide everything discussed above, but I was wondering if anyone had any feedback/suggestion as to this being a possible start to solving this issue?

Here's my code so far https://github.com/nedmas/silverstripe-mobile

@chillu
Copy link
Member

chillu commented Mar 6, 2013

Note: I've added some rudimentary is_tablet() detection with e4d2600 and cca2096. Its no less hacky than the current detection, but allows for some basic logic switching. In the end, the whole approach of user agent detection is flawed, which I've also noted in the README. Its technically impossible to distinguish a "tablet" running Windows 8 from a "desktop" doing the same thing (or a tablet with a wireless keyboard, sitting on a desk ... you get the point). See http://www.brettjankord.com/2013/01/10/active-development-on-categorizr-has-come-to-an-end/ and http://blog.cloudfour.com/responsive-design-for-apps-part-1/.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants