if this site looks broken its because you're using an old-ass browser! seriously like 10 years old! get a better one!

symfony Tip #15 - Returning a rendered partial from an action

15/09/2009 Posted in symfony Posted by: admin

When returning a rendered partial from an action like:

return $this->renderPartial('action/partial');

you can use all the $this->variables assigned in that action in the view, UNLESS you pass an array of them into the partial:

return $this->renderPartial('action/partial',array('var'=>'this stops us using any this->vars'));

which then becomes all you can use in there.

 

Post a comment: