Q:

Get Option Value by Id of Attribute in Magento

How can Magento find an attribute value by a given attribute label or a given attribute id?

A:

$productModel = Mage::getModel('catalog/product');
$str_attr_label = "color";  //or "size", etc...
$int_attr_id = 8; // or any given id.
$int_attr_value = 21; // or any given attribute value id.

// Chose either
if ($byLabel){
    $attr = $productModel->getResource()->getAttribute($str_attr_label);
}
if ($byId){
    $attr = Mage::getModel('catalog/resource_eav_attribute')->load($int_attr_id);
}

if ($attr->usesSource()) {
    echo $color_label = $attr->getSource()->getOptionText($int_attr_value);
}       

A:

Simply put - use the getAttributeText method.
$product->getAttributeText('brand')

