How to change CSS based on mobile device?

后端 未结 5 2212
一整个雨季
一整个雨季 2021-02-07 05:30

In the following example, I want to display only one div, depending on the device.

I\'m familiar with how to use @media to override a CSS cla

5条回答
  •  耶瑟儿~
    2021-02-07 06:05

    how to do a conditionnal css media query :

    @media only screen and (width : 1024px) and (orientation : landscape) {    
        .selector1 { width:960px; }
    }
    

提交回复
热议问题