How to get attribute Value and label by attribute ID without product in Magento
Get attribute Value and label by attribute ID without product in Magento
<?php $attribute = Mage::getModel('eav/config')->getAttribute('catalog_product', '136');?>
<?php foreach ( $attribute->getSource()->getAllOptions(true, true) as $option):?>
<?php $attributeArray[$option['value']] = $option['label'];?>
<?php echo "<pre>";?>
<?php $option['value'].'==>'.$option['label'];?>
?>
<?php endforeach;?>
136 is my Attribute id.
<?php $attribute = Mage::getModel('eav/config')->getAttribute('catalog_product', '136');?>
<?php foreach ( $attribute->getSource()->getAllOptions(true, true) as $option):?>
<?php $attributeArray[$option['value']] = $option['label'];?>
<?php echo "<pre>";?>
<?php $option['value'].'==>'.$option['label'];?>
?>
<?php endforeach;?>
136 is my Attribute id.
Please support us, Like us on Facebook.
Subscribe to:
Post Comments (Atom)
Also, you should always pay attention to charge the mobile using original chargers only.
ReplyDeleteHowever, the memories that you make as you travel are usually much better remembered if you have a good travel companion by your side to share and
document those memories with you. Some of the reasons behind this are the decline in prices of mobile
phones, convenience of usage, and affordable mobile internet rates.
Also visit my web blog ... multi vendor marketplace