Hi, I hope someone can help me out! I’m new to magento, and my PHP is a bit rusty, so I’m struggling a bit with what should be quite a simple problem. I’ve done a quick search but I couldn’t find any obvious thread about this.
Heres what I want to do:
I’m making a site for a specialist clothing retailer. On the home page, I’d like a list of types of products on the left (clothing, footwear, bags etc) with children categories (clothing -> shirts). On the right side I’d like a series of logos of brands (bolle, north face etc). Customers can then use either route to see relevant products.
Heres how I’m trying to do it:
I’ve created two sets of categories - one is the product type, stored under the Default Category. The other set is under a new category parent called Brands, and I’ve assigned them images. Products are members of two categories, one for product type and one for brand (both sunglasses AND bolle, for instance).
As suggested in this thread http://www.magentocommerce.com/boards/viewthread/5026/P15/ I’ve changed app/code/core/Mage/Catalog/Block/Navigation.php and added in a ->addAttributeToSelect(’image’) so that I can use the image URL.
Heres the problem:
I can’t work out how to specify that I only want to display children of one category in a list. In fact, at the moment Navigation.php doesn’t display my brands at all - presumably because they aren’t children of the default category. Can someone please suggest (preferably with a code snippet for the hard-of-thinking) how I can specify that I want a list of all the children of the “brands” category?
I’m sure this is a problem thats come up before, hopefully someone has an easy solution
Thanks in advance for any help - I’ve wasted a few hours on this one today, so I’m going to take a break from it and go back to bashing my head on the template/block structure in an effort to understand how that works instead!