✈️ Proposal for issues of 404 response for CSS files when using page caching #33162
robwent
started this conversation in
Feature Request
Replies: 2 comments
|
This is the single most needed elementor feature and every day i’m in disbelief they ship their product with such a gaping fault like this. Your plugin fix is perfect, thank you so much for it. Saved me so much stress… Tested and working with WP Rocket + Cloudflare. Will be including it on all my sites going forward, thanks again! |
0 replies
|
This is still needed one year later, hopefully this will be included as a fix soon into elementor! |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Description
There have been ongoing issues with missing CSS files when using page caching for some time.
EG:
#25075
#33057
#27300
Elementor clears out CSS files on an update, and they don't get regenerated until the page gets an uncached hit, leaving many pages broken if you don't totally purge all caches, slowing down your site.
I was intending to write a plugin to detect the 404 errors on css files and clear the W3 total cache of the related page, but this still has issues. The first hit to the page gets the broken styling, and the next hit gets an uncached page.
In issue 27300 I saw the call to regenerate the css.
So I created a proof-of-concept plugin here: https://github.com/robwent/elementor-css-regenerator
It detects 404 errors for Elementor CSS files before the 404 is returned, regenerates the requested file, sends it back to the browser with a 200 header, and the file gets saved again.
This way:
I understand that this issue may get buried with all the others, but I wanted to offer a solution to the open and closed issues that it's not possible to comment on.
Steps to reproduce
Expected behavior
Delete the css files -> css files get regenerated when requested.
Elementor System Info
[Removed by Moderator]
Agreement
All reactions