为什么CSS没有为max-device-width启用:480px?

时间:2012-04-13 12:03:00

标签: iphone css media-queries

media="(max-device-width: 480px), only screen and (-moz-min-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min-device-pixel-ratio: 2), all and (max-width: 480px)"

大家好,

CSS在桌面上工作正常,其视口为480px或更低,但不会在iPhone上启用。知道媒体查询代码有什么问题吗?

由于

1 个答案:

答案 0 :(得分:0)

您是否有视口元标记?

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">