Magento: CMS Blocks in Templates
The more I use this code snippet the more I keep having to dig this back up, so I’m posting it here for reference for others as well… Here’s the quick and easy way to insert CMS Blocks into template (.phtml) files without any layout modifications:
<?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('your_static_block_id_here')->toHtml() ?>Enjoy! ![]()
Possibly Related Posts:
- Magento vs X-Cart
- Magento version 2.0 (X.Commerce) and eBay
- Magento Supercharged Development Tools and Links
- Book Review: Magento 1.4 Themes Design by PacktLib
- Magento modules post deployment uninstall & downgrading
18May2009









