Get attributes from a static block in phtml : Magento
May 17, 2012
Static block is very useful in magento to make the site functional. When we create the static block it ask for some attributes like title, identifier, statuc and content. We know
How to add static block to your phtml file. Now here is the solution to get other attributes in phtml file.
For example we have a static block which identifier is "myidentity". Now using the belwo code we can get the attaributes from that static block.
$block = Mage::getModel('cms/block') ->setStoreId(Mage::app()->getStore()->getId())->load('myidentity');
echo $title = $block->getTitle();
echo $isActive = $block->getIsActive();
Hope it will help you. You can use it in your way. Cheers :)