我有一个响应式网站,除了safari之外,每个浏览器都能正常运行。
特别不尊重这一点:
<link type="text/css" rel="stylesheet" href="tablet.css" media="only screen and (min-width:481px) and (max-width:959px)" />
我尝试了以下内容:
<link type="text/css" rel="stylesheet" href="tablet.css" media="only screen and (min-device-width:481px) and (max-device-width:959px)" />
(这使得任何事都无效)
<link type="text/css" rel="stylesheet" href="tablet.css" media="only screen and (min-device width:481px) and (min-width:481px) and (max-device-width:959px) and (max-width:959px)" />
(这不会在任何浏览器上加载css文件)
我试过没有屏幕,不起作用。
是的我也有这个:
<meta name="viewport" content="width=device-width" />