开发者

Code ran before every action within symfony

I have code that I want to be executed before every action is called. Are there 开发者_如何学Caction hooks I can use for this?


In a module:

public function preExecute()
{

}

If you want it to be global for all modules, put it in the appConfiguration class, or create a filter.


+1 for filters. events can also be very useful, depending on what you want to do.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜