0

I am creating a module that adds an attribute to a product.

If the product has the attribute, on the category page I want to display 'has attribute' below the price and above 'Add to Cart'.

I'm concerned about overriding the template and want to know how best to proceed?

2
  • Depends on your theme. Commented Feb 17, 2014 at 13:29
  • The module is looking to be distributed, I'm basing it off base/default Commented Feb 17, 2014 at 14:18

2 Answers 2

0

Have you tried referencing product.info.extrahint in your layout xml for the catalog_product_view layout handle and adding your new Block in there? It's an instance of core/text_list and should render Any child passed to it.

0

The preferred method from my reading is to not override anything, add a new block and provide instructions for the user on how to add that block to their local.xml and call that block in their theme. This way your extension doesn't break anything that might not be compatible on install and gives the user or developer time to review what changes they might need to make so that it is.

Reference post #4

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.