0

I've to customise the bundle product options block. The default xml structure used by Magento is:

<action method="addRenderer">
<type>select</type><block>bundle/catalog_product_view_type_bundle_option_select</block>
</action>

Blocks are declared without any names, so I guess the remove tag doesn't work. How to remove a block from the layout xml? I tried to set a name, but it still doesn't work.

1
  • Can you clarify end result you're going for?
    – ladle3000
    Commented Aug 24, 2015 at 19:38

1 Answer 1

1

Take a look at the addRenderer() method:

/**
 * Add renderer for an option type, e.g., select, radio button, etc.
 *
 * @param string $type
 * @param string $block
 */
public function addRenderer($type, $block)
{
    $this->_optionRenderers[$type] = $block;
}

This means, if you call it again for a given type, it replaces the existing renderer:

<action method="addRenderer">
    <type>select</type>
    <block>your_module/your_select_renderer</block>
</action>
1
  • thank you very much, I'm now able to use different blocks using different product_bundle_type handles!
    – apedic
    Commented Aug 25, 2015 at 8:19

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.