X-Git-Url: http://git.inspyration.org/?a=blobdiff_plain;f=module%2FApplication%2FModule.php;h=6ab203c3d4f8e15546363417eb9bd6157fcfa218;hb=52f94fcc7087bb4b4134a0400ddedeba8c75175f;hp=a540a11f8d7d3f544843c47060db1cd6520438ed;hpb=7a482c8f4e56f572888c780da6c1912facd26850;p=zf2.biz%2Fgalerie.git diff --git a/module/Application/Module.php b/module/Application/Module.php index a540a11..6ab203c 100644 --- a/module/Application/Module.php +++ b/module/Application/Module.php @@ -2,19 +2,10 @@ namespace Application; -use Zend\Module\Manager, - Zend\EventManager\StaticEventManager, - Zend\Module\Consumer\AutoloaderProvider; +use Zend\Module\Consumer\AutoloaderProvider; class Module implements AutoloaderProvider { - public function init(Manager $moduleManager) - { - $events = $moduleManager->events(); - $sharedEvents = $events->getSharedCollections(); - $sharedEvents->attach('bootstrap', 'bootstrap', array($this, 'initializeView'), 100); - } - public function getAutoloaderConfig() { return array( @@ -33,13 +24,4 @@ class Module implements AutoloaderProvider { return include __DIR__ . '/config/module.config.php'; } - - public function initializeView($e) - { - $app = $e->getParam('application'); - $basePath = $app->getRequest()->getBasePath(); - $locator = $app->getLocator(); - $renderer = $locator->get('Zend\View\Renderer\PhpRenderer'); - $renderer->plugin('basePath')->setBasePath($basePath); - } }