Zend Provider | Set editor via the module config

This commit is contained in:
ghislainf
2013-04-24 02:19:26 +02:00
parent 7e8d4c3e5e
commit 37861ba641
2 changed files with 9 additions and 1 deletions
+7
View File
@@ -34,6 +34,13 @@ class Module
{
$prettyPageHandler = new PrettyPageHandler();
// Set editor
$config = $event->getApplication()->getServiceManager()->get('Config');
if (isset($config['view_manager']['editor'])) {
$prettyPageHandler->setEditor($config['view_manager']['editor']);
}
$this->run = new Run();
$this->run->register();
$this->run->pushHandler($prettyPageHandler);
@@ -2,12 +2,13 @@
/**
* ZF2 Integration for Whoops
* @author Balázs Németh <zsilbi@zsilbi.hu>
*
*
* Example controller configuration
*/
return array(
'view_manager' => array(
'editor' => 'sublime',
'display_not_found_reason' => true,
'display_exceptions' => true,
'json_exceptions' => array(