Initial translation setup
[zf2.biz/galerie.git] / module / Application / config / module.config.php
1 <?php
2 return array(
3     'router' => array(
4         'routes' => array(
5             'home' => array(
6                 'type' => 'Zend\Mvc\Router\Http\Literal',
7                 'options' => array(
8                     'route'    => '/',
9                     'defaults' => array(
10                         'controller' => 'Application\Controller\Index',
11                         'action'     => 'index',
12                     ),
13                 ),
14             ),
15             // The following is a route to simplify getting started creating
16             // new controllers and actions without needing to create a new
17             // module. Simply drop new controllers in, and you can access them
18             // using the path /application/:controller/:action
19             'application' => array(
20                 'type'    => 'Literal',
21                 'options' => array(
22                     'route'    => '/application',
23                     'defaults' => array(
24                         '__NAMESPACE__' => 'Application\Controller',
25                         'controller'    => 'Index',
26                         'action'        => 'index',
27                     ),
28                 ),
29                 'may_terminate' => true,
30                 'child_routes' => array(
31                     'default' => array(
32                         'type'    => 'Segment',
33                         'options' => array(
34                             'route'    => '/[:controller[/:action]]',
35                             'constraints' => array(
36                                 'controller' => '[a-zA-Z][a-zA-Z0-9_-]*',
37                                 'action'     => '[a-zA-Z][a-zA-Z0-9_-]*',
38                             ),
39                             'defaults' => array(
40                             ),
41                         ),
42                     ),
43                 ),
44             ),
45         ),
46     ),
47     'service_manager' => array(
48         'factories' => array(
49             'translator' => 'Zend\I18n\Translator\TranslatorServiceFactory',
50         ),
51     ),
52     'translator' => array(
53         'locale' => 'en_US',
54         'translation_patterns' => array(
55             array(
56                 'type'     => 'gettext',
57                 'base_dir' => __DIR__ . '/../language',
58                 'pattern'  => '%s.mo',
59             ),
60         ),
61     ),
62     'controllers' => array(
63         'invokables' => array(
64             'Application\Controller\Index' => 'Application\Controller\IndexController'
65         ),
66     ),
67     'view_manager' => array(
68         'display_not_found_reason' => true,
69         'display_exceptions'       => true,
70         'doctype'                  => 'HTML5',
71         'not_found_template'       => 'error/404',
72         'exception_template'       => 'error/index',
73         'template_map' => array(
74             'layout/layout'           => __DIR__ . '/../view/layout/layout.phtml',
75             'application/index/index' => __DIR__ . '/../view/application/index/index.phtml',
76             'error/404'               => __DIR__ . '/../view/error/404.phtml',
77             'error/index'             => __DIR__ . '/../view/error/index.phtml',
78         ),
79         'template_path_stack' => array(
80             __DIR__ . '/../view',
81         ),
82     ),
83 );