0
我想在我的web应用程序中使用谷歌字体。我的呼叫加载谷歌的字体是:如何在IE,Firefox和Chrome中使用谷歌网页字体
$.get("https://www.googleapis.com/webfonts/v1/webfonts?key=xxxxxxx", function (result) {
var data = {};
console.log(result);
console.log($.parseJSON(result));
data.items = $.parseJSON(result).items;
});
上述呼叫给出以下结果在我3个靶浏览器:
火狐
console.log(result); ========> JSON string
console.log($.parseJSON(result)); ========> Successfully parsed the json string
data.items = $.parseJSON(result).items; ===> contains all google fonts
IE(9)
$.get callback is not executing.
铬
console.log(result); ========> Object
console.log($.parseJSON(result)); ========> null
可有人告诉我使用谷歌的字体在所有上述3所述浏览器的通用方法是什么?