0

Is possible to create a child theme using various parents themes as template, instead of only a single parent?

Example: The child theme will be called 'Light', and his parents will be the theme 'Sky', the theme 'Color' and the theme 'Star'. It's possible call these three other themes in standard way to be the cores of the child theme?

1

It's possible call these three other themes in standard way to be the cores of the child theme?

I assume you mean "Is it possible..."? No. You can't use multiple themes as parents. WordPress is not built that way. Besides, how would you parse the logic? Suppose each parent had a tag.php template or an author.php. Which would be used? How would the system know? Then there is likely to be conflicting code in the functions.php file, possibly conflicting filters and actions,...

I am sure you could hack together a way to load various templates but it wouldn't be a "WordPress" child theme and it would be a nightmare to write and maintain.

1

No, this is not possible, even as a concept it requires further refinement to avoid fundamental problems.

For example, if your child theme has a single.php and WordPress tries to load page.php, it will load the page.php in the parent because it doesn't exist in the child theme.

But if we have multiple parent themes, which page.php should it load? What if we solved that problem but all these parent themes were wildly different, which almost certainly means they'd be incompatible with styling issues and broken layouts. If they were similar enough to work together you might as well merge them into a single theme.

We could try defining a hierarchy and using grandparent themes, but that's also not possible without changes, and has serious problems and difficulties. For example, what if a theme is it's own grandparent?

What I suspect is that this idea is a solution you came up for another problem, and you're now asking how to do this rather than working on the original

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.