Results 1 to 3 of 3

Thread: If mobile show certain content?

  1. #1
    Join Date
    Jun 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default If mobile show certain content?

    I'm working on creating a mobile css page for my site. however, one thing i have not related to css is certain content such as video's that appear. I want to basically say "if it's on a mobile device don't show these images"

    What is the best method to do so?

    Thanks,

  2. #2
    Join Date
    Jun 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default mobile ie6\5

    Since mobile ie6 and lower doesn't support media type, how to designate mobile css for those browsers?

  3. #3
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,164
    Thanks
    265
    Thanked 690 Times in 678 Posts

    Default

    Note: your posts have been merged into a single thread. Don't post twice. It may take more than 6 hours to reply... please be patient.


    While it is possible to do what you are suggesting, I don't think this is the right way to approach the problem.

    I suggest that you create a mobile site like m.example.com and redirect users on mobile devices there, or just tell them to go there.

    You can use a serverside language like PHP to check the user agent string and with some accuracy find out if they are on a mobile device. Alternatively you can use try to use Javascript to detect this, but that's not a good idea because many mobile devices may not use Javascript so that's not very useful.
    I don't believe there is a way using only css to do this.

    There might be a way to set a specific stylesheet for "mobile" as a default, but I expect that would only be recognized by some devices. Try google for "default mobile stylesheet" and see if you find anything. But again, that requires that the device uses it.
    Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

Bookmarks

Posting Permissions

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