2

We are using the Google Feed API to show blog posts on our site. However, it's has been over 24 hours and our latest post hasn't showed up on our site. We verified that the RSS feed has the latest post but it appears that Google still has the old data cached.

I found this question that suggests that adding a query string will bust the cache but every string I append causes the feed to fail.

Here is the working link to our feed: http://ajax.googleapis.com/ajax/services/feed/load?num=7&q=https:%2F%2Fsigwhatsnew.wordpress.com%2Ffeed%2F&v=1.0

Here is the feed with a query string added: http://ajax.googleapis.com/ajax/services/feed/load?num=7&q=https:%2F%2Fsigwhatsnew.wordpress.com%2Ffeed?foo%2F&v=1.0

I have tried every combination of query strings I can think of. Encoded and not encoded, before the trailing slash and after the trailing slash.

Can anyone post an URL that will bust the cache? Thanks in advance

Community
  • 1
  • 1
Scotty Bollinger
  • 2,343
  • 4
  • 19
  • 25

2 Answers2

0

One hacky way of accomplishing this is to set the parameter to a random integer...

This random parameter can also be a random number..
var randomNum = Math.floor((Math.random() * 10000) + 1);
var url = "http://ajax.googleapis.com/ajax/services/feed/load?" + randomNum + "?num=7&q=https:%2F%2Fsigwhatsnew.wordpress.com%2Ffeed%2F&v=1.0"

That way the browser assumes it's loading a new URL each time, while the Google Feed API ignores the value.

pxpgraphics
  • 1,357
  • 11
  • 21
  • This does not work as it is not the browser that caches bud the API. It began happening this week. – Gregor May 14 '15 at 07:24
0

Simply add parameter nocache after the url you provide.

https://ajax.googleapis.com/ajax/services/feed/load?v=1.0&q=http://myurl?nocache
Evan
  • 1,152
  • 1
  • 11
  • 18