zf2 How to implement template switching
use Zend\View\Model\ViewModel; // Add resource class IndexController extends AbstractActionController { public indexAction() { $viewModel = new ViewModel(); $viewModel->setTemplate('application/index/index'); return $viewModel; }
For details, see: http://framework.zend.com/manual/2.2/en/modules/zend.view.quick-start.html
For details, see: http://framework.zend.com/manual/2.2/en/modules/zend.view.quick-start.html