There appears to be a problem with this plugin on our hosting.
For some reason the permissions that are set for the new child-theme folder are missing execute bit, therefore the script fails saying it cannot create the new child theme’s
style.css
or
rtl.css
I believe the problem is due to the plugin calling
mkdir()
and
file_put_contents()
instead of wordpress internal equivalents.
I was unable to determine the correct way to initialize the wp_filesystem class (which should contain those methods) therefore I worked around the problem by performing these operation:
chmod($new_theme_path, FS_CHMOD_DIR);
chmod($new_theme_path.’/style.css’, FS_CHMOD_FILE);
chmod($new_theme_path.’/rtl.css’, FS_CHMOD_FILE);
Please consider updating your plugin to use wordpress internal filesystem object.
Thanks
— Relevad
https://ww.wp.xz.cn/plugins/one-click-child-theme/