Editing Columns, Footer, and Header in Magento

It takes a while to understand the structure of Magento, but once you get it, it becomes fairly logical.  When working with new themes, of free themes, sometimes they add static blocks that require some code-based editing to remove them.

I recently installed a new theme, and because I’m a do-it-yourself kind of guy, I didn’t want to pay for the people I got the theme from to also install it (the expensive part). In an attempt (I suspect), the added a few blocks that took me a while to find how to remove them, but once I found them, I felt kind of silly. It’s one of those situations where you start using a CMS friendly engine like Magento with a backend, and become overly dependent on it.

This particular situation I had two issues.

Right Column Block

The first problem was that there was a default Facebook block setup linking to the creators of the themes Facebook site. Since I am deploying this on a customers site, naturally I didn’t want this. However, I tried to search everywhere within the backend admin panel, and couldn’t remove it. Finally, I found the solution was as easy as removing a few lines of code from the 2columns-right.phtml file.

For your theme, you’ll want to browse to the folder: /app/design/frontend/<interface name>/<theme name>/template/page/

Inside this folder, you have a few more folders, but there are also a few *.phtml files. According to the template you’re using (1 column, 2 column, 3 columns), and the appropriate side column you want to edit (right or left), you should open this *.phtml file, and find the code that corresponds to the block you want to remove.

Your best bet for removing some code is to remove everything inside (and including) the <div><content to remove></div> tags.

Header and Footer *.phtml

Browsing now to: /app/design/frontend/<interface name>/<theme name>/template/page/html you will find the both the header.phtml and the footer.phtml files. This is where you’ll want to edit the information you want to manually change, for example, hard coded theme designer links.

Hope this helps!

Leave a Reply

eighteen − ten =