I want to pass a variable with the block code like of JSON type in magento,
{{block type="multibanners/multibanners" category_id="9" name="multibanners" alias="multibanners" template="multibanners/multibanners.phtml"}}
from cms pages content area , but I don’t receive any thing.
If I use block with action method than I easily get my value.
Anyone know how can I pass variable with my custom block?
I’m not 100% sure what you are asking, but if you are trying to pass a variable to
multibanners.phtmlfrom the code above then you could create another attribute similar tocategory_id="9"and inmultibanners.phtmlyou could get the value using$this->getData("category_id");e.g.
In
multibanners.phtml: