I have plugin who method show text. I would like call the function from my block in cms static block. How to do this? Any hints?
2 Answers
You have to call any block file from static block like :
{{block type="core/template" template="custom/custom.phtml"}}
and in this file you can call that plugin method and echo that value.
First of all, try to display your block in phtml to test if your block works fine like this:
<?php echo Mage::app()->getLayout()->createBlock('core/template')->setTemplate('yourfolder/yourfile.phtml')->toHtml(); ?>
If your Block work correctly you should call it in your cmc page like this
{{block type="core/template" name="your.block.name" template="yourfolder/yourfile.phtml"}}