
Untitled
By: a guest on
Jun 21st, 2012 | syntax:
None | size: 0.56 KB | hits: 20 | expires: Never
<?php
/* class for processing static pages */
class StaticController extends CommonController {
public function init() {
parent::init();
// turn off the default page rendering
$this->getHelper('viewRenderer')->setNoRender();
}
/* parse a view and output the given template */
public function parseViewAction() {
$view = new Zend_View();
$view->setScriptPath( MODULES_PATH . '/default/views/static');
// output a given page
echo $view->render( $this->_request->getParam( 'page').'.phtml');
}
}