Hi there,
thanks.
Well, actually the plugin did what everybody can do for a minute.
Yeah that’s the purpose of the plugin:
creates a theme folder with a reference to the parent theme in the child-theme style.css.
The only file required for a child-theme is a style.css where it’s declared that the theme is a child of a parent theme:
https://developer.www.ads-software.com/themes/advanced-topics/child-themes/#2-create-a-stylesheet-style-css
(see which are the required information)
That file and those information make a theme a child-theme.
The functions.php is not mandatory at all, as, most of the time (actually it’s a common practice), the parent theme will load the child theme style.css trough, something like this:
wp_enqueue_style( 'twentynineteen-style', get_stylesheet_uri(), array(), wp_get_theme()->get( 'Version' ) );
(in fact get_stylesheet_uri()
will return the child-theme folder if the active theme is a child-theme)
Unfortunately there’s no unique way to create a child-theme that will perfectly work with all the parent themes.
Some of them need the child-theme to enqueue its own style.css by itself, some other will take care about it, some other have the main CSS rules not placed in their style.css, and so on. For some of them the suggested methods to enqueue the child-theme stylesheet here:
https://developer.www.ads-software.com/themes/advanced-topics/child-themes/#3-enqueue-stylesheet
works fine, for some other it doesn’t, and so on.
I don’t want to overcomplicate the logic of this plugin to take in account all the possible edge cases. This plugin is simple and works for simple cases ??
I encourage you to try other plugins that will probably better suit your needs. ??
https://www.ads-software.com/plugins/search/child+theme/
Hope this helps.
p.s.
Here you can also find the reason why this plug-in creates the child-theme the way it does:
https://www.ads-software.com/support/topic/needs-update-12/