0

I have created a simple page that only shows JSON. The issue I have is that administrator users and anonymous users see different data.

screenshot

I assume this is a cache problem, but I am not sure, nor am I sure how to fix this.

I am new to Drupal but I was able to find this settings page, which shows that caching is disabled.

screenshot

Does anybody have an idea on what I can do?

5
  • Which set of data is correct? The data shown to auth users or the data shown to anon users? – Patrick Kenny Dec 26 '20 at 12:13
  • @PatrickKenny Data shown to the auth users is correct. – skrat Dec 26 '20 at 15:44
  • Try clearing the Drupal caches manually with drush or the admin UI (/admin/config/development/performance). There are other caching layers in Drupal in addition to Views caching, and there may be additional caching outside Drupal depending on how your server is set up. So you have to find at which level the data is getting cached. – Patrick Kenny Dec 26 '20 at 15:53
  • @PatrickKenny Manually flushing all cache does the job! Of course, I need to somehow automate the cache flushing or stop caching at all. – skrat Dec 26 '20 at 15:57
  • 1
    You said you made a page, but actually the settings page you are showing is for a Views Block, not a Views Page. Since you set the block not to be cached in the Views UI, the block is probably getting cached with the page that it is being attached to. One way to get around this is to make a Page display in Views instead of a Block display. You can do that by opening the view and adding a page from the button in the upper right corner. – Patrick Kenny Dec 26 '20 at 16:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.