Kriuchko
1/9/2019 - 11:38 AM

Crossell products

Magento 1 crossell products


\!h ----- on product page

Hello, To move the Cross Sell Box from Shipping Cart Page to the Product Detail Page, you can follow these steps: 1. Remove the Cross Sell Box from Shipping Cart Page: Open the file app/design/frontend/default/your_theme/layout/checkout.xml (or app/design/frontend/base/default/layout/checkout.xml), find and comment this code:
<block type="checkout/cart_crosssell" name="checkout.cart.crosssell" as="crosssell" template="checkout/cart/crosssell.phtml"/>

2. Add the Cross Sell Box to the bottom of Product Detail Page: - Add this code to the bottom of the file app/design/frontend/default/your_theme/layout/checkout.xml (or app/design/frontend/base/default/layout/checkout.xml)
<catalog_product_view>  <reference name="product.info">   <block type="checkout/cart_crosssell" name="checkout.cart.crosssell" as="crosssell" template="checkout/cart/crosssell.phtml"/>  </reference> </catalog_product_view>

- Open the file app/design/frontend/default/your_theme/template/catalog/product/view.phtml (or app/design/frontend/base/default/template/catalog/product/view.phtml), add this code to the bottom:
<?php echo $this->getChildHtml('crosssell'); ?> 


\!h ----- crossell dont exclude products не исключать добавленные в корзину продукты ———

/app/code/local/Mage/Checkout/Block/Cart/Crosssell.php
public function getItems