I used this excellent plugin to export and import Customizer settings from production down to the development copy: https://wordpress.org/plugins/customizer-export-import/
This shouldn’t be necessary, though.
It’s repeatable–I’ve gotta restore Customizer settings each time I copy the database down.
Hi @salzano,
Sorry for your experience.
I just tried to use your exfil script to clone down a staging site of ours which also uses a child theme (took me a while to find out what production_root_path means ;)). But everything got copied without any issues — the values from the customizer got copied correctly.
A question for you: since you are working locally, the child theme is mostly a symlink into wp-content/theme, that also might be a git repository. Can you confirm that in the local and production sites the folder name of the child theme is the same? If it’s not the same — a simple DB export/import won’t get the values transported correctly.
Customizer values are prefixed with theme’s folder name in the DB, so if they don’t match you won’t see the actual values (even though they’re technically there).
Also, can you please activate the parent theme both locally and on the production site and do a sync? Will the customizer get synced correctly in this case? If it will, then the above theory will be confirmed.
Please keep me posted — I’ll help with what I can. I really doubt this is a theme issue since we don’t change anything in the underlying storage mechanism for customizer options.
Best regards,
Andrei.
Hi. Here’s the child theme: https://www.dropbox.com/s/74y3ks20gp7t5li/blocksy-baby.zip?dl=0
The folder name is the same for both local and production copies of the theme. Perhaps enqueuing style.min.css instead of the version with the header comment in functions.php is causing the problem. I can test it the other way.
Sorry, that test still lost the page layout setting of “boxed” and deleted all my footer content and settings like previous migrations.
Thanks for your attention on this issue & the feedback on exfil. I’ll improve the doc.
@salzano, thank you for the link