google-feed-api

Google Feed Loader API ignoring XML attributes

≯℡__Kan透↙ 提交于 2019-11-29 08:43:52
Google's feed loader appears to be ignoring attributes when converting to JSON. I'm using jQuery to grab a feed via AJAX. The actual RSS XML feed can be seen here , and the response from the AJAX call can be seen here . I need to access the url attribute of the <enclosure> tags, but neither appear in the response. For reference, the code I am using is: function getFeed(url) { url = 'http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=10&callback=?&q=' + encodeURIComponent(url); $.ajax({ type: 'GET', url: url, dataType: 'jsonp', cache: false, success: function(d) { alert(JSON.stringify

Prevent Google Feed API from using cached feed

两盒软妹~` 提交于 2019-11-28 12:10:19
I am using the Google Feed JSAPI to read/parse a feed. The problem is, when the feed changes, the previous entries become invalid (links and images don't work) so I cannot load a cached version of the feed. I thought there would be an option when loading the feed to not use the cached version but I don't see one. My solution is to do add in a variable (t) to the end of the feed url so it is "unique" but this seems hacky (but it works). Anyone know of a better way to do it? function onLoad() { // Create a feed instance that will grab feed feed. var feed = new google.feeds.Feed(feedLocation+"&t=

Google Feed Loader API ignoring XML attributes

…衆ロ難τιáo~ 提交于 2019-11-28 02:05:40
问题 Google's feed loader appears to be ignoring attributes when converting to JSON. I'm using jQuery to grab a feed via AJAX. The actual RSS XML feed can be seen here, and the response from the AJAX call can be seen here. I need to access the url attribute of the <enclosure> tags, but neither appear in the response. For reference, the code I am using is: function getFeed(url) { url = 'http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=10&callback=?&q=' + encodeURIComponent(url); $.ajax(

Prevent Google Feed API from using cached feed

北慕城南 提交于 2019-11-27 06:47:44
问题 I am using the Google Feed JSAPI to read/parse a feed. The problem is, when the feed changes, the previous entries become invalid (links and images don't work) so I cannot load a cached version of the feed. I thought there would be an option when loading the feed to not use the cached version but I don't see one. My solution is to do add in a variable (t) to the end of the feed url so it is "unique" but this seems hacky (but it works). Anyone know of a better way to do it? function onLoad() {