css - 媒体查询不适用于 iPad

标签 css ipad media

下面的代码在 iPad 上没有做任何事情,尽管与桌面相比字体应该更大......这是怎么回事?

<style type="text/css">
@media screen and (min-device-width: 481px) and (orientation:landscape) {
.header {
font-family: courier new, monospace;
color: #999999;
font-size: 16pt;
line-height: 12pt;
width: 38.25em;
 }
}
.header {
font-family: courier new, monospace;
color: #999999;
font-size: 12pt;
line-height: 12pt;
width: 38.25em;
}
</style>

最佳答案

尝试将@media 查询移到另一个头类下面,我相信第二个头类正在覆盖您的媒体查询

关于css - 媒体查询不适用于 iPad,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17793170/

相关文章:

cordova - 如何知道设备的媒体音量是静音还是很低

android - MediaMetadataRetriever getFrameAtTime : videoframe is a null pointer

html - 表格在 Internet Explorer 中的 div 中不对齐

jquery - 让每个 div 在 0.2 秒后依次淡入,而不是异步淡入

jquery - 单击链接时的下拉菜单

iphone - ARC 和 MBProgressHUD

ios - MPMoviePlayerController 在全屏模式后使应用程序处于不正确的方向

iphone - 防止缩放到一定限度

html - Angular Bootstrap Carousel - 在不拉伸(stretch)的情况下使图像适合方框

node.js - Node (套接字)实时音频流/广播