I found that you can set data to the view from block by setting it to your xml file. Is there's a way to set it without accessing your xml file? And another question, how can I pass data from controller to block?
相关问题
- Android ContextMenu for View (Not Activity)
- Magento 1.7.0.2 Index Management overwriting URL R
- Magento: Best way to avoid extension conflicts
- Magento Fatal error: Maximum execution error solut
- Templates In Kohana 3.1
相关文章
- What the logcat message: “E/MoreInfoHPW_ViewGroup(
- Magento, translate validation error messages
- Magento API order id vs. increment id
- Do I need NO LOCK in my CREATE View query
- Unique constraint violation on Magento 1.4.0 to 1.
- Editing Magento sales e-mail payment block
- How to call a method once the completion block fin
- Adding tags to products in Magento
For passing data from block to view
In block use
In template use
For passing data from controller to block
It's not the responsibility of the controller to set variables for the view.
Controller set values from Models and block retrieves values from that model.
You can do this by:
Varien_object
In the controller, instantiate that object using this code:
Later access the variable by
Hope you got what was needed :)