Home › Forums › WoodMart support forum › Recently Viewed (Gutenberg) and W3 Total Cache
Recently Viewed (Gutenberg) and W3 Total Cache
- This topic has 11 replies, 2 voices, and was last updated 1 day, 11 hours ago by
Artem Temos.
-
AuthorPosts
-
July 11, 2025 at 10:43 am #673067
AlexParticipantI display the Recently Viewed on all pages through the Gutenberg Products block (from the theme)
Update with AJAX on page load – is enabled
I noticed a problem: if W3 Total Cache caching is disabled – the block works correctly, if W3 Total Cache caching is enabled, then products that the person has not visited appear in the block and a strange sequence. At the same time, I have already made many exceptions in W3 Total Cache so that there are no problems with the theme, it is probably not enough and some more are needed.
How to check:
When viewing pages at the bottom before the brand carousel, you will see the Recently Viewed blockFor those authorized on the site (for example, in the admin): I have caching disabled – the block will work correctly
For those not authorized: I have caching enabled – the block will work incorrectlyJuly 11, 2025 at 10:53 am #673072
Artem TemosKeymasterHello,
Please record a video that demonstrates the problem so we can understand and reproduce it on your website.
Kind Regards
July 11, 2025 at 11:48 am #673088
AlexParticipantExample of a problem in the video: previously cleared the browser cache and cookies, incognito mode on the video.
The first 3 products were added to the block normally, when switching to 4, another product is visible in the block, to which the transition was not made (the end of the video – yellow packaging). Most likely, another user was accessing the site at the same time, it was cached and returned to me. If you do the same with an authorized user (in the admin), then you will not find such a problem.
July 11, 2025 at 11:55 am #673090
AlexParticipantThe problem is easier to identify if another user or several (from a different IP) access the site in parallel and visit another product.
It just happens that when there is 1 user, then the problem may not be seen, if there are several – it is more obvious
July 11, 2025 at 5:59 pm #673505
Artem TemosKeymasterCould you please provide us with your FTP access so we can troubleshoot this issue?
July 11, 2025 at 6:09 pm #673507
AlexParticipantHold on, I just don’t know how to fix this via FTP. And why is this access needed?
July 14, 2025 at 3:12 pm #673823
Artem TemosKeymasterIt is somehow related to the custom code in your child theme https://monosnap.com/file/RS7HUa6RfTGtmksnfTmNZM7xphZasP
Try to remove it and test how it works.July 14, 2025 at 4:31 pm #673866
AlexParticipantRemoving the code fragment did not help (I added it as an additional element according to the data https://rankmath.com/kb/exclude-sitemaps-from-caching/)
If it is related to the sitemap, then it is possible through this W3 Total Cache function:
Page Cache section, Cache Preload block:
– Update interval
– Pages per interval
– Automatically prime the page cache
– Sitemap URLJuly 14, 2025 at 4:45 pm #673868
AlexParticipantAnother (unlikely) reason is the use of Speculation rules (prerender, eager)
July 16, 2025 at 9:08 am #674426
Artem TemosKeymasterTry to apply the patch
674350
and clear your browser cache. Let us know how it works.July 16, 2025 at 11:27 am #674475
AlexParticipantI cleared the cache and cookies. I confirm that the problem with the incorrect display of the last viewed products has been resolved. Thank you very much!
July 16, 2025 at 2:22 pm #674525
Artem TemosKeymasterGreat, you are welcome! Feel free to contact us if you have any further questions.
-
AuthorPosts
Tagged: #W3 Total Cache, recently viewed
- You must be logged in to create new topics. Login / Register