Fixed Strange behaviour while page loading/refreshing - “cookies notice” appearing then disappearing?!

VBX Co

Well-known member
See here for video example of what is happening: https://xenforo.com/community/threa...-refreshing-the-page-“cookies-notice”.156229/

Just upgraded a site to 2.2.12 and this behaviour has started straight afterwards; doing it in Chrome, Opera and Firefox.

When first visiting you get the expected cookie notice and click to accept. No problem, but from then on each time you load a page on the site you get the pop-up quickly appear and disappearing again (as per video in first post).
  • Cleared caches etc. no difference.
  • Hit ESC key to "catch" it whilst the page loads and when clicking on it, it takes you to the login page (need to be logged in to do that).
Any idea what may be causing this please?
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.13).

Change log:
Fix simple cookie notice flash for guests
There may be a delay before changes are rolled out to the XenForo Community.
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.13).

Change log:

There may be a delay before changes are rolled out to the XenForo Community.

That's great - thanks for the quick response - is it something I can manually apply in the meantime?
 
I’ve not seen this, but when I set it to the new beta “GDPR mode”, I couldn’t get rid of the prompt. Haven't gotten round to reporting it properly yet.
 
Last edited:
The bug wouldn't affect the accept button taking you to the log in page. That would generally indicate that JS has not loaded properly, which is likely just a side-effect of pausing the loading to catch the notice flash. In any case, I can't reproduce that behavior locally or on your site when allowing the page to load fully.

In any case, you can replace js/xf/preamble.min.js with the attached file to fix the flashing.
 

Attachments

It's likely a caching issue (either locally or an intermediary such as Cloudflare). You can rebuild your master data (via /install or php cmd.php xf:rebuild-master-data) to change the cache-buster query string.
 
It's likely a caching issue (either locally or an intermediary such as Cloudflare). You can rebuild your master data (via /install or php cmd.php xf:rebuild-master-data) to change the cache-buster query string.
Thanks again - that seems to have done the trick! :)
 
Code:
[ivvvicool@glc21 ~]$ php cmd.php xf:rebuild-master-data
Could not open input file: cmd.php
[ivvvicool@glc21 ~]$
Any help please?
 
You would want to run the command from the XF root (or just browse to /install to do it via the web interface).
 
Back
Top Bottom