How to fix an issue with customizer live preview?
Setting up a css.php for this purpose is overkill (or undesirable in any case, as @MarkKaplun states in the other answer). The smoothest way for previews of css is using jquery (see part 3 of the customizer API). Since you’re not using the transport argument in your setting, the page is reloaded anyway, so you … Read more