سؤال

im new to this, where can i find the php controller code that loads the following template file in:

<reference name="product.info.options.wrapper">
    <block type="catalog/product_view_type_configurable" name="product.info.options.configurable" as="options_configurable" before="-" template="catalog/product/view/type/options/configurable.phtml"/>
</reference>
هل كانت مفيدة؟

المحلول

Controllers do not load templates.
Controllers load layout handles that contain blocks that are rendered by template.
The xml section you posted means is located in the layout handle PRODUCT_TYPE_configurable.
this layout handle is loaded by
Mage_Catalog_Helper_Product_View::initProductLayout() that is called by Mage_Catalog_Helper_Product_View::prepareAndRender() that is called by Mage_Catalog_ProductController::viewAction(),
but only when viewing a configurable product.
So the controller you are looking for is Mage_Catalog_ProductController.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى magento.stackexchange
scroll top