CSS仅适用于移动设备

时间:2017-04-25 13:03:51

标签: css iphone mobile

我希望绿色和红色的盒子在移动设备上小巧(iPhone):http://shop.cykel-expressen.dk/booking/

我认为这是代码,但它不起作用,但不起作用)):

@media all and (min-width:321px) and (max-width: 480px) .dopsp-body { .dopsp-body height: 50xp }

4 个答案:

答案 0 :(得分:1)

{

后,您遗失了(max-width: 480px)
@media all and (min-width:321px) and (max-width: 480px) {
  .dopsp-body { height: 50px }
}

答案 1 :(得分:0)

您可以使用媒体查询。

Dictionary<string, int>

答案 2 :(得分:0)

你使用的是错误的方法,试试这个。

@media screen and (max-width: 480px){
//Reduce the size of green and red box here
}

答案 3 :(得分:0)

首先尝试的是第二个用于横向的横向代码http://stephen.io/mediaqueries/有很多好的代码段

console.log(data)

//  [{
//    ID: "5545",
//    Pref: "Liberty"
//  },{
//    ID: "8946545",
//    Pref: "Growth"
//  }]