I have looked at this: Google Web Fonts don't work in IE8, and this: How to make Google Fonts work in IE?. Neither works for me. The first suggests not to import too many fonts at once, while the latter is out of date since the bug was fixed back in 2010.
The HTML is as follows:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Font Test</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Google Fonts Test">
<link type='text/css' href='https://fonts.googleapis.com/css?family=Cantarell' rel='stylesheet'>
<link type='text/css' href='https://fonts.googleapis.com/css?family=Play:700' rel='stylesheet'>
<link type='text/css' href='https://fonts.googleapis.com/css?family=Muli:300' rel='stylesheet'>
<!--<link type='text/css' href='//fonts.googleapis.com/css?family=Lato:900' rel='stylesheet'>-->
<link type="text/css" href="https://static.mysite.com/blah/font-test.css" rel="stylesheet">
</head>
<body>
<div class="page-title">
This Is Title
</div>
<div class="page-content">
This is content
</div>
</body>
</html>
This is the corresponding CSS:
body {
height: 100%;
width: 960px;
min-height: 550px;
max-height: 1080px;
margin: 20px 60px 40px 20px;
padding-left: 10px;
padding-right: 10px;
background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAGCAYAAADgzO9IAAAAKklEQVQIW2OceOe1cb6K6FkGJAASYwTxkSVhbLAETBJEw3Tjl8BqFC7LAdSSJR3onNbEAAAAAElFTkSuQmCC) repeat;
}
.page-title {
height: 55px;
font: 38px "Play";
}
.page-content {
font: 16px "Cantarell";
width: 630px;
text-align: justify;
}
The above is tested in latest Chrome, which works fine. It however does not work in IE8 for some reason. Anything I am missing?
UPDATE: IE8 simply does NOT work with Google Fonts API. In fact, if I use IE8 to browse the specimen of many fonts on the Google Fonts API pages, none of them renders correctly. The only sure way to use these fonts is to convert them to EOT
type (among with WOFF
type), and serve them from your server, which is a shame because you cannot use Google's CDN anymore.