Archived topic
Passing Customizer Settings From A Custom Child Theme
3 replies · Started by codesignwp on December 15, 2020
I am working on a wp multisite where all the subsites will use the same theme as in layout, header, footer etc.
Right now I am exporting the customizer data and importing it manually on each site.
Is there a way I can automate that process?
Like passing the customizer settings value form the child theme functions.php
I found a solution,
add_filter('generate_option_defaults', function ($defaults) {
$defaults['container_width'] = '1500';
$defaults['layout_setting'] = 'left-sidebar';
return $defaults;
});
But it doesn't work out of the box it works when only I open the customizer in wordpress and save the settings.
Anyways to completely overwrite the theme-defaults?
But it doesn’t work out of the box it works when only I open the customizer in wordpress and save the settings.
Turn off 'dynamic_css_cache'
Glad you got it sorted - thanks for sharing! :)