ie不兼容,分别对样式进行处理
一.
<!DOCTYPE html> <!--[if IE 7 ]> <html class="ie7" xmlns="http://www.w3.org/1999/xhtml" lang="zh-CN"> <![endif]--> <!--[if IE 8 ]> <html class="ie8" xmlns="http://www.w3.org/1999/xhtml" lang="zh-CN"> <![endif]--> <!--[if IE 9 ]> <html class="ie9" xmlns="http://www.w3.org/1999/xhtml" lang="zh-CN"> <![endif]--> <!--[if (gt IE 9)|!(IE)]><!--> <html xmlns="http://www.w3.org/1999/xhtml"> <!--<![endif]-->
加上以上,则可以对ie各个浏览器样式进行设置
<style> .ie7 div{ width:100px; } </style>
作者:chenze 出处:https://www.cnblogs.com/chenze-Index/ 本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。 如果文中有什么错误,欢迎指出。以免更多的人被误导。 |