We devided all the products into two categories:
- "Main products"
- "Accessories"
All listed products from the category "Main products" are opened with our custom template: catalog/product/view_main_producs.phtml
Here it comes the tricky part :)
All products from the category "Accessories" needs to be opened with different custom template catalog/product/view_accessories.phtml, because the products from this category have different attributes.
In some way we managed (partly) to acchive this with the following lines of code:
<reference name="product.info">
<action method="setTemplate"> <template>catalog/product/view_accessories.phtml</template></action>
</reference>
We inserted the above code into "Accessories" category Custom Design -> Custom Layout Update
With the above code we managed to open products from category "Accessories" into on our custom view_accessories.phtml template!
Here is what is the problem. Above code only works if a person came to our web site through the links on our web site.
Now we have two issues:
- If person come to our web site and search for accessories products (search toolbar), the product will not be opened in view_accessories.phtml template!
- If person click on the products while searching for it on google, bing (SEO search), the product will not be opend in "view_accessories.phtml"!
Our question is: how to achieve for all products from "accessories" category to be opened in "view_acccessories.phtml" - no matter how come the person access the link?
Thanks in advenced :)