3

I have magento 2 and a requirement to show a certain category, subcategories and product pages in those categories using a different layout then other product pages on my store.

So just to be clear:

  • I have a category page which shows a list of subcategories
  • I have a sub category page which shows a list of products and a product page

each one of the above has a different functionality then other categories/products of my site.

So, I have a theme that I created that I assigned to the category and the subcategories that I need. It works great. But, I did not find a way to assign a theme to a product page. I had to assign the theme to the entire site for the theme to be applied to product pages. This defeats what I need to do

Am I missing something? What is the right approach?

1

1 Answer 1

0

So here the general idea I would follow:

  • create a global theme for all your pages EXCEPT the product page
  • create a specific theme ONLY for your product page
  • assign your global theme to your entire site
  • in your product configuration, enable your product specific theme (under Schedule Design Update)

enter image description here

3
  • your approach will work, but takes a lot of effort. I have to assign a theme to each product and if i change a theme, i must do it on every single product Oct 25, 2016 at 11:00
  • actually this is what i wanted. I wish it could inherit the theme from the category. would make my life easier Oct 25, 2016 at 11:01
  • @OvedYavine you can totally inherit the product specific theme from your global theme: devdocs.magento.com/guides/v2.0/frontend-dev-guide/themes/… Oct 25, 2016 at 11:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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