Skip to content

Instantly share code, notes, and snippets.

@phamquocbuu
Created December 17, 2013 12:43
Show Gist options
  • Save phamquocbuu/8004356 to your computer and use it in GitHub Desktop.
Save phamquocbuu/8004356 to your computer and use it in GitHub Desktop.
Zend Routes to sub-dir
protected function _initRoutes()
{
$this->bootstrap('frontcontroller');
/**
* @var Zend_Controller_Front $front
*/
$front = $this->getResource('frontcontroller');
/**
* @var Zend_Controller_Router_Rewrite $router
*/
$router = $front->getRouter();
$router->addRoute('www2',
new Zend_Controller_Router_Route(
'dn24/:controller/:action',
array('controller' => 'index',
'action' => 'index'))
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment