I have a custom attribute in Magento for a grouped product minimum priced RRP. I want to be able to pull this through into the product grid within my theme, however, i cannot find whether this is possible or not. The attribute is simply called 'rrp'.
Originally i had this:
$_item = $this->getItem();
$_product= Mage::getSingleton('catalog/product')->load($_item->getProductId());
$rrp = $_product->getResource()->getAttribute('rrp')->getFrontend()->getValue($_product);
But if i go
<?php echo $rrp; ?>
it simply does not work.
Am i missing something?
Full code here for my 'featured grid' - http://pastebin.com/mn8BYvwA
// Use entity id to load a product.
$oProductModel = Mage::getModel( 'catalog/product' )->load( 1 );
$sRrp= $oProductModel->getData( 'rrp' );
var_dump( $sRrp );
$sFormat = $oProductModel->getAttributeText( 'rrp' );
var_dump( $sFormat );
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.