0

In this project we had one frontend custom theme working, to do some customizations. That is working fine. Let's call that Theme1/custom (with Magento/blank as parent)

Now we have created a new frontend custom theme, let's call it Theme2/custom, whose parent is Theme1/custom

Both themes are working, but we are experiencing some issues when trying to override some layouts & templates

Let's say we have one customized template in app/design/frontend/Theme1/custom/Magento_Catalog/templates/product/list.phtml & now we need to override that same file in the new custom theme, so we have placed our changes in app/design/frontend/Theme2/custom/Magento_Catalog/templates/product/list.phtml

I am starting to think this approach is not valid when dealing with custom themes extending custom themes... Because project still loads the Theme1/custom one

Cache & static content are fresh, and permissions are ok

Any ideas?

update

This issue appears to affect only Magento_Catalog module... which makes that totally weird...

5
  • That method is valid, I have been working on a site that has an identical fallback. Magento Blank > Theme 1 > Theme 2 and it works fine
    – Ben Crook
    Jun 20 '18 at 15:56
  • Mmm... Maybe we have missed some file in theme configuration then, but it's strange, as some overrides are working fine Jun 20 '18 at 16:00
  • can you paste composer.json of your Theme 2 please? or tell me if you have there any reference to Theme1? Jun 20 '18 at 16:23
  • Nope there is no reference to any of the custom themes in composer.json, all the theme code is inside app/design/frontend
    – Ben Crook
    Jun 21 '18 at 8:01
1

Weird problems usually have weird solutions

All was working fine, but some catalog categories in project had checked attribute "Use parent category settings", and that parent category had forced the original Theme1/custom

2
  • That sounds like a potential bug, surely that should only apply to settings and not themes. Unless you set the theme against that category via a setting?
    – Ben Crook
    Jun 21 '18 at 8:53
  • 1
    I suppose someone made that configuration change in root category, when original theme was designed. I mean, that was a human action Jun 21 '18 at 8:55
0

Please check your parent tag <parent>Magento/blank</parent>

In theme.xml file (path Vendor/theme/theme.xml)

And run all commands.

And double check your theme names

In your example path they started from Capital letters

7
  • But the parent of Theme2 should be Theme1/custom, if that's what you mean Jun 20 '18 at 15:57
  • joxi.ru/4Ak7R3YIyykpJA Should start from small letter Jun 20 '18 at 15:59
  • This should work. Look for typo Jun 20 '18 at 16:00
  • Typo in examples were just after changing real names for the ones posted, they are fine in filesystem... this is tricky :S Jun 20 '18 at 16:08
  • Maybe you can share your file structure and content of main theme files There is mine: joxi.ru/MAjya0wu44keb2 Jun 20 '18 at 16:23

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.