Accessing a Magento Static Block From a .phtml Template File
<?php
// Retrieve the layout object
$layout = Mage::getSingleton('core/layout');
// Generate a CMS block object
$block = $layout->createBlock('cms/block');
// Set the block ID of the static block
$block->setBlockId('block-id-in-magento');
// Write the static block content to screen
echo $block->toHtml();
?>
Written by Wayne Roddy
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Magento
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#