To Redirect:
/controllers/yourcontroller::youAction()
$this->_redirect('/path/to/place');
To Show Profiler in a layout
/layouts/yourlayout.phtml
$this->addScriptpath(APPLICATION_PATH . '/profiler/views/scripts');
echo $this->render('util/profiler.phtml');
/application/profiler/views/scripts/util/profiler.phtml
getProfiler();
if($profiler->getEnabled() && $profiler->getTotalNumQueries() > 0) { ?>
Database Profiling Report
Total queries executed: getTotalNumQueries()?>
Total elapsed time: getTotalElapsedSecs()?>
# | Query | Time |
---|---|---|
() | getQuery();?> | getElapsedSecs();?> |
Disable Zend Layout:
$this->_helper->layout->disableLayout();
source: Web Development Blog