NetTalk Central

Author Topic: Use of the Mobile checkbox  (Read 4790 times)

John Fligg

  • Sr. Member
  • ****
  • Posts: 361
    • View Profile
    • Ambrit Software
    • Email
Use of the Mobile checkbox
« on: December 07, 2011, 01:33:15 AM »
I am not looking for a total solution, but just some general guidance.

I intend defining Mobile Users as those using anything other than a Smartphone. That is so I can use the Mobile checkbox that if it unchecked will hide controls. IOW Smartphone users see only a limited dataset whereas iPad, Netbook and above see all the controls.

No problem there. But equally I want to change the menu type depending on this. That would go by screen size.

Is there some common code/utility that detects the screen size and allows me to change the actual menu type.

Sorry I have not read up yet on CSS and the like so just wondered before I started on work in a particular area of design.

John

John Fligg

  • Sr. Member
  • ****
  • Posts: 361
    • View Profile
    • Ambrit Software
    • Email
Re: Use of the Mobile checkbox
« Reply #1 on: December 10, 2011, 04:20:18 AM »
Not had any response to this so hoping this re post might generate something.

John

ccordes

  • Sr. Member
  • ****
  • Posts: 384
    • View Profile
    • Email
Re: Use of the Mobile checkbox
« Reply #2 on: December 10, 2011, 10:59:45 AM »
Here is an example of detecting and altering your css with  jQuery
http://www.ilovecolors.com.ar/detect-screen-size-css-style/

Might help get you started
Real programmers use copy con newapp.exe

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Use of the Mobile checkbox
« Reply #3 on: December 10, 2011, 10:18:38 PM »
bear in mind that the "mobile" menu type is automatically "switched to" when a mobile device is detected.

cheers
Bruce

John Fligg

  • Sr. Member
  • ****
  • Posts: 361
    • View Profile
    • Ambrit Software
    • Email
Re: Use of the Mobile checkbox
« Reply #4 on: December 11, 2011, 01:03:00 AM »
Thansk Bruce but this was my original point.

Exactly what IS a mobile device?

So do I use code to detect screen size and leave that mobile check box unchecked? For my users a mobile device is either a Smartphone or an iPad (or imilar) both of which have totally different screen sizes.

So basically I think what i am asking is that if you check the mobile checkbox you need some criteria somewhere to define what mobile is.

John

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Use of the Mobile checkbox
« Reply #5 on: December 11, 2011, 10:09:24 PM »
at the moment we're treating touch based devices as mobile. But you can of course override the IsMobile method in WebHandler to adjust that if you like.

cheers
Bruce

John Fligg

  • Sr. Member
  • ****
  • Posts: 361
    • View Profile
    • Ambrit Software
    • Email
Re: Use of the Mobile checkbox
« Reply #6 on: December 12, 2011, 01:03:18 AM »
Thanks Bruce - that is interesting.

Smartphones - no issue.

iPad (I hate them!!!) - depends on how they use them. Vertically and they are a grandiose smartphone and should be treated accordingly regards screend esign, but run them horizintally and they effectively become a Netbook and could display more information.

I can just see my iPad clients saying they want the application to show more than a smartphone.

So maybe we need something like if screen size <= whatever then it is a smartphone stype.
If > whatever then it is NOT  a smartphone style UNLESS it is run vertically in which case it is.

I am not sure that is practical or is it?

Thanks

John

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Use of the Mobile checkbox
« Reply #7 on: December 12, 2011, 01:56:45 AM »
I don't think basing it on orientation is practical, or indeed a good idea. No site that I'm aware of changes the site behavior and layout based on orientation. That would be very surprising to the user, and hence a bad thing.

Allowing you access to the screen size though is something I'm looking into.

cheers
Bruce

John Fligg

  • Sr. Member
  • ****
  • Posts: 361
    • View Profile
    • Ambrit Software
    • Email
Re: Use of the Mobile checkbox
« Reply #8 on: December 12, 2011, 02:16:45 AM »
In hindsight I totally agree.

I have a Dell Inspiron Duo that acts exactly like an iPad and running the app vertically the smartphone style is great, horizontally looks a bit strange. However that is down to my design I suspect. But access to the screen size would really help.

Thanks

John