Hi I changed the code to: ------------------------------------------------------------------------------- namespace Application;
use Zend\Mvc\ModuleRouteListener; use Zend\Mvc\MvcEvent; use Zend\EventManager\EventInterface; class Module { //.. public function onBootstrap(EventInterface $event) { $app = $event->getParam('application'); $layout = $app->getMvcEvent()->getViewModel(); if( $app->getRequest()->isXmlHttpRequest() ) { var_dump($layout->setTerminal(true)); } } } ------------------------------------------------------------------------------- The if works, and the layout should be terminated, but it doesn't work. pic: <http://zend-framework-community.634137.n4.nabble.com/file/n4659151/120t7xg.jpg> -- View this message in context: http://zend-framework-community.634137.n4.nabble.com/Don-t-display-layout-if-ajax-request-tp4659147p4659151.html Sent from the Zend Framework mailing list archive at Nabble.com. -- List: fw-general@lists.zend.com Info: http://framework.zend.com/archives Unsubscribe: fw-general-unsubscr...@lists.zend.com