- minicart in
Hi all – Here is my solution to a question I’ve seen asked many times: How to move the cart sidebar into the header area. You can use this technique to move it anywhere. This is not the only way to do this, but it is a useful one.
1) Copy the the block for the cart side bar:
04.//there is also this full code in my version 1.1.3
2) Open up app\design\frontend\default\default\layout\page.xml (assuming you are using the default design or didn’t create a new page.xml file in your own templates)
Find the code :
1. //near line 58
Within that block, you will see other sub-blocks.
Paste your new block in there. Add the “as” attribute and set it to “topcart” — final result:
3) Finally, go into app\design\frontend\default\default\template\page\html\header.phtml (again, assuming your using default theme) and add the code:
1.//place this where ever you want the cart to show up.
2. getChildHtml(‘topcart’); ?>
Removing the cart in a CMS page would also be handy to know:
In the Update Layout XML area, use:
You might have to wrap this in (name changing dependent on your design)