XML – modify the Magento Front Tab to Custom View: Suitable for bundled products

I want to display other details of sub-products in the case of bundled products.

So I did the following, adding extras to the bundled products
I used the following XML code in the admin “custom layout update”




description
Description
catalog/product_view_description



additional
Additional
core/template



tags
Tags
tag/product_list



review
Reviews
review/product_view_list< br />


But I can’t see any changes.

But when I remove “catalog_product_view” from the code above, use the following code:



description
Description
catalog/product_view_description
< template>catalog/product/view/description.phtml


additional
Additional
core /template



tags
Tags
tag/product_list



review
Reviews
review/product_view_list


I can see the “additional” details in the magento front-end tab, but on the product list page, I see the following fatal error:

p>

Call to a member function getId() on a non-object in 

D:\wamp\www\myfo lder\app\code\core\Mage\Review\Block\Product\View\List.php on line 40

Please guide me to achieve this goal.

The error is the review block. View the blocked calls for a specific product. When you open any product detail page, product_id will be set to object but the object is null , So getId() is wrong. Make sure you are passing the product_id to block the page.

I want to display other details of sub-products in the case of bundled products.

So I did the following and added extra details to the bundled product.
I used the following XML code in the admin “Custom Layout Update”

< pre>


description
Description
catalog /product_view_description



additional
Additional
core/template




tags
Tags
tag/product_list



review
Reviews
review/product_view_list



But I can’t see any changes.

But when I read from the above code When deleting “catalog_product_view” in the “catalog_product_view”, use the following code:



description
Description
catalog/product_view_description



additional
Additional
core/template



tags
Tags
tag/product_list



review
Reviews
review/product_view_list


I can see the “additional” details in the magento front-end tab Information, but on the product list page, I see the following fatal error:

Call to a member function getId() on a non-object in 
< br />D:\wamp\www\myfolder\app\code\core\Mage\Review\Block\Product\View\List.php on line 40

Please guide me to achieve this goal.< /p>

The error is the review block. View the blocked calls for a specific product. When you open any product detail page, product_id will be set to object but the object is null, so getId() error. Make sure you are passing product_id to block the page.

Leave a Comment

Your email address will not be published.