terrid25
terrid25

Reputation: 1946

Magento - including CMS content in templates

I have created a new layout templates in apps/frontend/default/my_theme/template/page and named it home-page.phtml and I have added my own html to this template.

The layout has 3 sections, that are promotional images and I'd like to include these on my homepage.

I have included the code:

 echo $this->getChildHtml('right');

and this seems to display some other images and a poll.

What I'd really like to so, is to include some kind of centent that can be managed in the CMS instead of the content that is outputted when using the above code.

Is this possible and how do I do it?

Kind regards

Upvotes: 1

Views: 1334

Answers (1)

demonkoryu
demonkoryu

Reputation: 1257

Simple:

<?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('cms_block_id')->toHtml() ?>

Upvotes: 5

Related Questions