1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Web Design based on Mobile Operating system?

Discussion in 'HTML & Website Design' started by Klikkit, Jun 11, 2013.

  1. #1
    I'm looking for a method of designing a website that detects the following;

    1: Whether the OS is desktop or Mobile
    2: If mobile, iOS/Windows or Android?
    3: Resolution

    What are the best ways to go about this? and possibly integrate with a current desktop wordpress theme?
    Klikkit, Jun 11, 2013 IP
  2. Deepak Chaubey

    Deepak Chaubey Member

    Messages:
    28
    Likes Received:
    0
    Best Answers:
    1
    Trophy Points:
    31
    #2
    Use PHP for Automatic Detection of desktop and mobile version.
    Deepak Chaubey, Jun 11, 2013 IP
  3. jamjar919

    jamjar919 Well-Known Member

    Messages:
    315
    Likes Received:
    6
    Best Answers:
    5
    Trophy Points:
    105
    #3
    An easy way to do this is with a media query. Media queries are CSS rules that come into place when a condition is true. I'm not sure that this would work for different OS's but definitely works when, say, the screen size (Viewport) drops below a specific point.
    jamjar919, Jun 11, 2013 IP
  4. xira

    xira Member

    Messages:
    315
    Likes Received:
    8
    Best Answers:
    4
    Trophy Points:
    43
    #4
    Media queries do not detect OS. They only can detect the media being used and the screen sizes. If you need to know the statistics of who is using what, you can do that via Google analytic. I wouldn't recommend creating different designs based on OS. They are always upgrading and changing. A screen size based media query is a much better approach. Many WP themes already have media queries as part of their coding.
    xira, Jun 12, 2013 IP
  5. Keltichiro

    Keltichiro Member

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    31
    #5
    If you're just wondering what operating systems and browsers your users are using, you can use Google Analytics for that.

    If you're meaning that you want your website to detect these things in order for your site to respond to the screen size/resolution, then you're going to want media queries for this.
    Keltichiro, Jun 22, 2013 IP
  6. deathshadow

    deathshadow Prominent Member

    Messages:
    5,978
    Likes Received:
    825
    Best Answers:
    144
    Trophy Points:
    395
    #6
    I think your intent is unclear -- are you looking for said information for tracking purposes, or are you literally looking at it for design purposes?

    Generally speaking if for design, then I think the question is the antithesis of rational accessible site design. It's the same concept as browser sniffing, which is a half-assed way of building sites that sane developers have shunned almost since it was introduced. It's ok to detect capabilities - like screen size with media queries; but targeting specific devices is just making sure anyone on anything different is left out in the cold.
    deathshadow, Jun 22, 2013 IP