I have created a new attribute on magento 1.9 and called category_grouped. Now I am trying to get it’s value on catalog page by using getAttributeRawValue but all I am getting is an ID. How could I get the value name rather than the ID? Below is my code. Thanks
<?php $attributeId = Mage::getResourceModel('catalog/product')-
>getAttributeRawValue($_product->getID(), 'category_grouped', $storeId);?>
2
Answers
The getAttributeText gets the value / name of the given attribute while getAttributeText return in this case the ID.
You can set attribute value by using below code
Thanks