I have created attributes; “Shop by Type” and “Shop by Color”. They work great within the layered navigation and extended search. I’ve designed graphics and placed them in the home page and would like to link to the respective attribute’s assigned products. Been searching the webs, but so far have been unsuccessful.
If there’s no direct possible way, the next method would be creating cms pages and linking to it directly. How can I display products that are assigned to a specific attribute? Specifically “Multiple Select” types.
I know you guys prefer at least some attempts, but as mentioned, been playing with it with no luck. I would appreciate some kind of starting point.
Happy Holidays!
Edit: I was able to put together this code that lists all the products assigned to said category id. Tried to filter it down where it only displays products that have an assigned same attribute with no luck yet. Any ideas?
<?php
$cat_id = 123; // category id
$category = Mage::getModel('catalog/category')->load($cat_id);
$_products = $category->getProductCollection()
->addAttributeToSelect('shop_by_color');
if (($this->getProductCollection()) && $_products->getSize()): ?>
By the way, $cat_id is a sub category of root. Is there an easier way to point to it instead of using direct id number?