[Resolved] CDN Issue, when using "Customize" to edit theme appearance


  • Author
  • #3959



    First off, I just wanted to say that I love your theme, and have purchased a copy of it for every site I’ve made in the last 5 months. I’m just running into one (hopefully small) issue.

    I’ve noticed that display changes I make in “Customize” (font color, background color, header height) do not work if I enable a CDN (KeyCDN for my site). The settings still show up as correct, when I go into Customize, but do not display. They just revert to the defaults. If I disable the CDN, everything reverts to working correctly. I do have a Child Theme that I’m working with, and changes made through that remain. Is there any way to export “Customize” settings to add to it, or would it be possible to get some pointers which things are being set for those 3? Thanks!



    Andrew Misplon

    Hi Dan

    Thanks for your support, it’s most appreciated.

    I’ll test with KeyCDN tomorrow and try figure out where the problem is.

    Just an idea; the Customizer outputs its styles inline in the document head, Certain caching plugin settings could in theory negatively impact this or perhaps move the inline block into a compressed stylesheet, perhaps above the theme’s style.css file in terms of cascading order. Are you using a caching plugin along with KeyCDN? If the answer is yes, did you disable the caching plugin and the CDN in testing or just the CDN?

    With regards to your child theme, the theme slug changes when we activate a child theme in WordPress. This unfortunately, cases the Customizer and Menu Location settings to reset. This is an expected result. I have seen a workaround for this problem. If it sounds like this is the core of the challenge, let me know and I’ll investigate the workaround further.

    I’ll reply ASAP tomorrow (GMT+2).

    Thanks 🙂



    Thank you Andrew!

    I am just using caching on the server level, via .htaccess. I do have the Autoptimize plugin set up.

    Here’s the results of my testing:

    Autoptimize On, KeyCDN Off: Works as expected
    Autoptimize Off, KeyCDN Off: Works as expected

    Autoptimize On, KeyCDN On: Breaks all settings in Customize > Theme Design (goes to defaults, although the Customize menu shows correct settings)

    Autoptimize Off, KeyCDN On: Works as expected

    Based on this, it looks like the easiest thing to do would be to exclude that in-line CSS from Autoptimize. What should I be looking for in the original code, to exclude?



    Ok, found an option to exclude inline CSS from Autoptimize, and that did it. Looks like it was the combination of both that gave me the issue. Thank you very much for your help!



    Andrew Misplon

    Super, really glad to hear you were able to resolve. Thanks for sharing the solution. I’ve been enjoying using KeyCDN lately. Really like their credit pricing over the normal flat rate packages elsewhere.

    All the best with your site. If anything else comes up, please, let us know 🙂

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

Scroll to top