How to change the position of module of magento cart?


Question

How i change the position of module of magento cart (top/button...left/Right)??

1
0
9/25/2015 8:11:22 AM

The quick and dirty way is to change the checkout.xml layout file.

open

frontend/default/default/layout/checkout.xml

find the line that says

<reference name="right">
    <block type="checkout/cart_sidebar" name="cart_sidebar" template="checkout/cart/sidebar.phtml" before="-">
        ............................
    </block>
</reference>

and change reference name to left,top,root,content etc... This determines the position of the cart in the layout

<reference name="left">
    <block type="checkout/cart_sidebar" name="cart_sidebar" template="checkout/cart/sidebar.phtml" before="-">
        ............................
    </block>
</reference>

You may have to clear your cache or delete /var/cache to see your changes.

The proper way to this would be to override the checkout Module , look at the magento wiki to learn more about overriding modules.

3
6/23/2009 9:29:59 AM

Licensed under: CC-BY-SA with attribution
Not affiliated with: Stack Overflow
Icon