Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Mike Naberezny's Blog:
Symfony Templates and Ruby's ERb
Feb 20, 2008 @ 13:12:36

In his latest blog entry, Mike Naberezny takes a look at the Symfony framework and shares some of his opinions on it.

One thing that I think Symfony gets right is that it appears to use partitioned PHP code for its templates, in the spirit of Paul's Savant system.

I noticed in the Symfony demo that there is no separation of scope between variables passed to the template from the controller and local variables in the template. I'd like to see them scoped properly ("$this->products") but I can certainly understand why they did it this way. Using "$this->" in the template everywhere quickly gets messy.

He mentions a few other items he saw as well, including a way to correct the above mentioned problem (two ways - one more single-instance, the other more global).

tagged: symfony template ruby ERb scope short_open_tags symfony template ruby ERb scope short_open_tags

Link:

Mike Naberezny's Blog:
Symfony Templates and Ruby's ERb
Feb 20, 2008 @ 13:12:36

In his latest blog entry, Mike Naberezny takes a look at the Symfony framework and shares some of his opinions on it.

One thing that I think Symfony gets right is that it appears to use partitioned PHP code for its templates, in the spirit of Paul's Savant system.

I noticed in the Symfony demo that there is no separation of scope between variables passed to the template from the controller and local variables in the template. I'd like to see them scoped properly ("$this->products") but I can certainly understand why they did it this way. Using "$this->" in the template everywhere quickly gets messy.

He mentions a few other items he saw as well, including a way to correct the above mentioned problem (two ways - one more single-instance, the other more global).

tagged: symfony template ruby ERb scope short_open_tags symfony template ruby ERb scope short_open_tags

Link:


Trending Topics: