cssiphonemedia-queries

Media Queries - CSS only for iPhone landscape


Are the same methods used to write CSS only for iPhone in landscape mode?


Solution

  • You could do this

    <meta name="viewport" content="width=device-width, 
        minimum-scale=1.0, maximum-scale=1.0">
    

    That forces the iPhone to render viewport the same as the device width.

    Then use this css to target the landscape mode, which is +320px wide

    @media screen and (min-width: 321px){
        //styles
    }