Take the 2-minute tour ×

In magento blocks what does block type means as in the below block?

<block type="core/template" template="example/view.phtml" />

Please help me in learning magento module development.

Is there some good resource?

share|improve this question
The Magento Developer API's are right here: magentocommerce.com/support/magento_core_api I'm not sure if that helps. –  nmagerko Dec 26 '11 at 18:24
The Magento API is a layer that sits on top of the normal Magento system and offers a (mostly) stable set of methods to call via SOAP, RPC, etc. It's an abstraction ABOVE the base PHP code that Sohail is trying to understand. –  Alan Storm Dec 26 '11 at 19:32

2 Answers 2

up vote 6 down vote accepted

The block "type" is a PHP Class. In a normal system, a


block type will become a Mage_Core_Block_Template class.

As for resources, start here (self link)

share|improve this answer
Thanks @Alan Storm. –  Sohail Dec 27 '11 at 4:54
I have one more question, if all I want to include .phtml file which will contain some code, I want to include this file in the right of the page. What block type would I use? –  Sohail Jan 3 '12 at 6:31
You'd use a core/template block. The type of the block and the area of the page that a block shows up in are two different things. –  Alan Storm Jan 3 '12 at 17:49
Thanx Alan Storm –  Sohail Jan 4 '12 at 5:28

Here's what I learnt -

type refers to the PHP file that will provide the methods for this phtml. Examaple:

/app/code/local/modstorm/Block/Filename.php , where all your methods for this block resides. So if, for example, you are have something like $this->getMethodName() in your .phtml, you must have getMethodName() function declared in /app/code/local/modstorm/block/Filename.php.

Hope this helps others as well.

share|improve this answer

Your Answer


