En el
manual sale todo.
En la acción:
Código PHP:
$this->_helper->layout->disableLayout();
$this->_helper->viewRenderer->setNoRender(true);
Forma más extremista:
Código PHP:
<?php
class FooController extends Zend_Controller_Action
{
public function init()
{
$this->_helper->layout->disableLayout();
// Local to this controller only; affects all actions, as loaded in init:
$this->_helper->viewRenderer->setNoRender(true);
// Globally:
$this->_helper->removeHelper('viewRenderer');
// Also globally, but would need to be in conjunction with the local
// version in order to propagate for this controller:
Zend_Controller_Front::getInstance()->setParam('noViewRenderer', true);
}
}
Si vas a trabajar con AJAX deberías usar
ContextSwitch and AjaxContext Action Helpers.
Saludos,