Fixes for render AJAX HTMLRender objects
This commit is contained in:
@@ -145,10 +145,14 @@ abstract class lnApp_Controller_TemplateDefault extends Kohana_Controller_Templa
|
||||
$this->meta->description = sprintf('%s::%s',$this->request->controller(),$this->request->action());
|
||||
|
||||
// For any ajax rendered actions, we'll need to capture the content and put it in the response
|
||||
} elseif ($this->request->is_ajax() && isset($this->template->content) && ! $this->response->body()) {
|
||||
} elseif ($this->request->is_ajax()) {
|
||||
$output = Style::factory()->render_all();
|
||||
$output .= Script::factory()->render_all();
|
||||
$output .= $this->template->content;
|
||||
|
||||
if (! isset($this->template->content) AND $this->response->body())
|
||||
$output .= $this->response->body();
|
||||
else
|
||||
$output .= $this->template->content;
|
||||
|
||||
$this->response->body($output);
|
||||
}
|
||||
|
Reference in New Issue
Block a user