After calling renderPartial, save return result and call afterRender this way:
$view = 'myView'; // etc
$output = $this->renderPartial($view, array(...));
$this->afterRender($view, $output);
Question
afterRender()
controller method invokes after render()
, but not afterrenderPartial()
.
Is there a solution?
Solution
After calling renderPartial, save return result and call afterRender this way:
$view = 'myView'; // etc
$output = $this->renderPartial($view, array(...));
$this->afterRender($view, $output);
OTHER TIPS
If you need to do it regularly, override renderPartial
in a CController
class and call afterRender
in there.