I’ve written a Drupal block and an ajax call to refresh it(block content) whenever the block is loaded.(It’s because i have enabled the cache).
But now my problem is whenever i go to a cached page, i’m getting a response – “304 Not Modified”. Because of that i’m not getting the correct content i want.
I found a solution such that to pass a number – new Date().getTime() – so that although the page is cached, since the next request is having another number, i’m getting correct values. But this seems quite “ugly”. 🙂
Is there another way to do this task?
thanks….
Use cacheexclude module to exclude that URL from cache.