I worked with magento for a while, and there are some details that I'm trying to understand how it works, a block and templates, for example, a part that I don’t understand, how you can do it in a template (.phtml file)
$this->getFunctionName();
this means that there is a function with this name in the block to which this template has been assigned.
I am trying to write a simple example to see how it works, but I cannot figure it out, so far, I just have a headeach.
How can I use $ this in a .phtml file to call block functions? It seems that .phtml is part of the object, right?
thanks
source share