html – 在Opera中使用100%min-height,但在其他浏览器中不能
发布时间:2020-12-14 19:38:11 所属栏目:资源 来源:网络整理
导读:这是我正在使用的代码: html,body{ height: 100%;}div{ min-height: 100%; height: auto !important; height: 100%; /* this is for older IE */} http://jsfiddle.net/YYcLJ/ 这也失败了(但在Opera中有效): div{ min-height: 100%; height: auto;} 所以10
这是我正在使用的代码:
html,body{ height: 100%; } div{ min-height: 100%; height: auto !important; height: 100%; /* this is for older IE */ } http://jsfiddle.net/YYcLJ/ 这也失败了(但在Opera中有效): div{ min-height: 100%; height: auto; } 所以100%的高度应该应用于所有div,直到html.但这只发生在第一个DIV (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |