How to make Google Fonts work in IE?

后端 未结 11 751
抹茶落季
抹茶落季 2020-11-28 03:17

I\'ve been developing a site that uses the Google Fonts API. It\'s great, and supposedly has been tested in IE, but when testing in IE 8 the fonts simply don\'t get styled.<

11条回答
  •  情话喂你
    2020-11-28 03:30

    Looks like IE8-IE7 can't understand multiple Google Web Font styles through the same file request using the link tags href.

    These two links helped me figure this out:

    • See this open Google issue, and look at the comments.
    • Also see this StackOverlow Answer Google Web Fonts don't work in IE8

    The only way I have gotten it to work in IE7-IE8 is to only have one Google Web Font request. And only have one font style in the href of the link tag:

    So normally you would have this, declaring multiple font styles in the same request:

     
    

    But in IE7-IE8 add a IE conditional and specify each Google font style separately and it will work:

    
    

    Hope this can help others!

提交回复
热议问题