Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS CSS Media Query Issue

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #36782
    fjorko
    Member

    I have some media queries based on screen size:

    I am currently testing on two different screen sizes ( 1920 x 1080 ) and another ( 1600 x 900 ). The first snippet is not triggered if the page I am viewing is opened on the 1600×900 screen. The query that DOES apply is the second snippet for 1680 x 1050px screens


    @media screen and (max-device-width:1600px){

    html{
    background:lightblue url(../img/logo.png) no-repeat 280px 200px;

    }

    }

    @media screen and (max-device-width:1680px){

    html{
    background:lightblue url(../img/logo.png) no-repeat 270px 200px;

    }

    }

    Any idea why ?

    #97193
    chuckpreslar
    Member

    Sounds like you’re not reaching the condition for your larger query. Try using only one query with a min-width of 1601, placing the style for the larger resolution inside of it while the smaller needs no condition met to be displayed.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.