html - How to use conditional comments correctly? -
can write css ie bugs in 1 conditional load?
<!--[if lt ie 9]> <link href="ie.css" rel="stylesheet" type="text/css" /> <![endif]-->
if make 1 conditional comment lt ie 9, can write css ie7 , ie8 inside or need make 2 different stylesheets?
if want use different stylesheet each version of ie, need make different conditional each one; linking unique stylesheet. lt
stands 'less than', alternatively, there lte
, 'less or equal'.
<!--[if ie 7]> <link href="ie7.css" rel="stylesheet" type="text/css" /> <![endif]--> <!--[if ie 8]> <link href="ie8.css" rel="stylesheet" type="text/css" /> <![endif]--> <!--[if ie 9]> <link href="ie9.css" rel="stylesheet" type="text/css" /> <![endif]-->
alternatively, if want use same stylesheet all versions of ie less or equal 9, use:
<!--[if lte ie 9]> <link href="ie.css" rel="stylesheet" type="text/css" /> <![endif]-->
Comments
Post a Comment