• Hello!

    I am experiencing an issue related to the WP Fastest Cache plugin on my website. The problem seems to be that a CSS file generated by the Spectra (UAG) plugin is incorrectly cached, resulting in a 404 (Not Found) error when the page is loaded for the first time.

    The specific file causing the issue is:
    /wp-content/uploads/uag-plugin/assets/0/uag-css-2.css

    Here are the details of the issue:

    1. When WP Fastest Cache is enabled, the CSS file fails to load, which deforms the page layout.
    2. Disabling WP Fastest Cache resolves the issue, and the file loads correctly.
    3. I added an exclusion for this file (and even the entire folder /wp-content/uploads/uag-plugin/assets/) in the plugin settings, but the issue persists.
    4. Disabling CSS minification also didn’t resolve the problem.

    It appears that WP Fastest Cache is not handling dynamically generated CSS files from Spectra properly.

    Could you please assist me in diagnosing and resolving this issue? Are there any additional settings or steps I should take to prevent this problem?

    Thank you in advance for your help, and I look forward to your response.

    Best regards.

    • This topic was modified 2 months, 3 weeks ago by ewooc.

    The page I need help with: [log in to see the link]

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Author Emre Vona

    (@emrevona)

    This is the expected result. when a page is cached, the page is saved as a static html file, so PHP does not work.

    Thread Starter ewooc

    (@ewooc)

    I don’t get it. The expected?result is not to load css files?

    Plugin Author Emre Vona

    (@emrevona)

    if the css is generated after creating cache, the css file cannot be detected.

    Thread Starter ewooc

    (@ewooc)

    So how can I resolve this problem?

    Plugin Author Emre Vona

    (@emrevona)

    when is the css source generated? is it generated by an optimization plugin?

    Thread Starter ewooc

    (@ewooc)

    It is generated by spectra page builder. I dont know how to check when.

    Plugin Author Emre Vona

    (@emrevona)

    The plugin owner should find a solution for this issue because the same problem occurs with all cache plugins.

    if the css is generated after creating cache, the css file cannot be detected.

    Emre, when page optimization is disabled, or when the path is excluded from optimization, it shouldn’t matter whether the file is there or not. As long as the stylesheet link is in the HTML, it can be used by the browser, even if this requires PHP processing on the server.

    @ewooc Just to confirm, are you clearing the cache with JS/CSS every time you change settings to test?

    Also, your page contains several uag-css stylesheets, and only one of them is causing a problem. Since all of them are minified, could there be a problem with the file itself?

    Finally, could this be caused by the nested use of output buffers?

    Plugin Author Emre Vona

    (@emrevona)

    It is not related to the optimization feature. For example, if the CSS source is uag-css-2.css and a page is cached, the HTML source will reference uag-css-2.css. However, if a new file, such as uag-css-3.css, is created, the CSS may break because the cached page still points to the outdated uag-css-2.css file.

    According to this page, Spectra considers using CSS files a great feature for caching. This implies that whenever those files are generated, they don’t change, but the page cache may need to be cleared every time this happens.

    @ewooc Perhaps ask the Spectra authors to trigger page cache clearing (specifically for popular caching plugins, like WP Fastest Cache) whenever CSS/JS files are generated.

    Hi @ewooc,

    Perhaps I can help. Also, I support what Emre shared with you. Grab a cup of coffee. Enjoy the read.

    Our website uses Avada (theme) which also generates dynamic CSS files (one for each of our pages). We are not experiecing any issues with WPFC. The only time we experience issues is when we inline our CSS files, improperly combine our CSS files, use incompatible performance plugins, and when we fail to clear properly our cache layers.

    Solution: (perform steps below in the given order)

    1. Do not minify CSS/JS files via Astra and clear all cache generated by Astra.
    2. Do not inline nor combine your CSS files. Enable “File Generation.”
    3. Click on “Regenerate Assets.”
    4. Go to WP Menu > Settings > Permalinks and click on “Save Changes.”
    5. Clear all cache from all plugins that generate cache (except WPFC).
    6. Clear all cache from WPFC.
    7. Clear all cache from any CDN you might be using.
    8. Clear all cache and cookies from all browsers you’re using.
    9. Launch your website in Incognito or Private mode for evaluation.

    Did the above solve your issue?

    If Yes, then remember not to inline your CSS files and to clear your cache in the above order when making changes to your website. Additionally, if you would like to combine your dynamic CSS files (one unique combination per page) and solve many of your issues, use a performance plugin such as Perfmatters which will also eliminate unused CSS.

    If No, then follow these instructions, contact the developers of Spectra, or use another plugin. It appears you’re using Spectra Pro, so I would contact them for premium support.

    Best wishes!

    Notes:

    1. I ran a test of your website (home page) and your issues go beyond WPFC. Honestly, I would try to solve these issues first and these (without WPFC). Your HTML file size is extremely high, you have many render-blocking files, and many other 3rd-party/plugin issues.
    2. I’m not affiliated with Perfmatters nor WPFC.

    Hey @ewooc,

    Final tips:

    1. Do not enable plugin features that conflict with each other. For example, do not enable combine CSS and/or JS in two (or more) plugins at the same time.
    2. Perform a plugin conflict test. For example, disable all plugins (except Astra and WPFC) then test WPFC caching features to see if that helps. Also, try using another Gutenberg native pagebuilder other than Spectra (test on a staging site).
    3. To fix most of your issues, use both Perfmatters and WPFC (in lieu of any other caching/performance plugins). Our team has tested numerous caching/performance plugins and these two plugins work the best for us.
    4. If none of the above helps, hire an expert from Upwork (with experience in WordPress, Astra, Gutenberg pagebuilders, WooCommerce, and CSS/JS/PHP coding) or WP Johnny to solve your issues. You won’t regret it.

    Again, best wishes!

Viewing 12 replies - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.