dcsimg
www.webdeveloper.com
Results 1 to 2 of 2

Thread: General Way to Identify Mobile Browsers

  1. #1
    Join Date
    Mar 2010
    Posts
    672

    General Way to Identify Mobile Browsers

    Is there a general way to identify mobile browsers other than cross checking the users user agent string with a large array of known user agents? The reason i am asking is that i don't really need anything too extensive or computationally intensive, just the identification if the browser is a mobile one.
    I just recently found out that mobile browsers are a bit buggy with position:fixed content (why god why!? thought that was an issue of the past with ie6...). So i'd rather hide the fixed position div than have it hang around the middle of the page for mobile browsers.
    If you're wondering, the fixed position div is declared at the bottom of the page, the logic being that if the browser didn't support position:fixed; then it would simply display it at the bottom. But i was surfing the site on an android phone and found that the browser attempts to position it fixed, but fails. It tries to jump into place as you scroll down, but eventually it just reaches a point on the page and stays there, not moving at all.

  2. #2
    Join Date
    Feb 2011
    Location
    israel
    Posts
    157
    i think you can use "@media handheld" in your style sheet to change the display.
    this explains:
    http://www.w3schools.com/css/css_mediatypes.asp

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles