Reputation: 2180
I am trying to learn mediaqueries and I need some help.
My code is not working in IE8
CSS
body {
font-size:11em;
color:#000;
transition:all .5s ease-in-out;
-o-transition:all .5s ease-in-out;
-moz-transition:all .5s ease-in-out;
-webkit-transition:all .5s ease-in-out;
}
@media screen and (max-width:500px) {
body {
font-size:5em;
color:#ff0000;
}
}
</style>
HTML
<body>
az a s d a sd
</body>
Please suggest, what should I do to make it run in IE8 or lesser? I added css3-mediaqueries.js in </head>
section (you can see code mentioned below) but it's not helping me.
<!-- css3-mediaqueries.js for IE less than 9 -->
<!--[if lt IE 9]>
<script src="http://css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js"></script>
<![endif]-->
Thanks in advance :)
Upvotes: 1
Views: 6505
Reputation: 1403
If css3-mediaqueries.js wont work - try Respond. Just keep this as a note as well for using CSS3-mediaqueries.js - it's from their site ->
Note: Doesn't work on @import'ed stylesheets (which you shouldn't use anyway for performance reasons). Also won't listen to the media attribute of the
<link>
and<style>
elements.
Upvotes: 3