1

我通过 Ajax 调用获得了 Pinterest 板提要。然而,结果中看不到墙上的变化。我一直在寻找解决缓存的方法。但我似乎在实施它时遇到了问题。

//url to the feed
var url = 'http://pinterest.com/' + this.options.username + '/feed.rss?nocache=' + (new Date).getTime();

///Google service
var api = "http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&q=" + encodeURIComponent(this.url) + "&num=" + this.options.limit + "&output=json_xml&callback=?";

这会引发错误:

Uncaught TypeError: Cannot read property 'feed' of null

{"responseData": null, "responseDetails": "Feed could not be loaded.", "responseStatus": 400}

当我省略'?nocache='+(new Date).getTime() 时。已加载缓存的提要。

4

0 回答 0