在html中可以使用如下代码进行兼容性编程:
<!--[if IE 8]>仅IE8可识别<![endif]-->
<!--[if lte IE 8]> IE8及其以下版本可识别<![endif]-->
<!--[if lt IE 8]> IE8以下版本可识别<![endif]-->
<!--[if gte IE 8]> IE8及其以上版本可识别<![endif]-->
<!--[if gt IE 8]> IE8以上版本可识别<![endif]-->
<!--[if IE]> 所有的IE可识别<![endif]-->
<!--[if !IE]>--除IE外都可识别<!--<![endif]-->(对ie10及以上版本可识别)
如上问题为兼容性问题的js脚本问题, 针对此类问题我们可以自己编写函数来解决此类问题:
//类似于divs = document.getElementsByClassName(