child_routesの設定に問題があります。私がそれらを分離しない限り、それらは機能しません、しかし、最終結果は同じであるはずです!:
これは私が達成しようとしていることです:
'router' => array(
'routes' => array(
'app' => array(
'type' => 'Zend\Mvc\Router\Http\Segment',
'options' => array(
'route' => '[/:info]/app',
'defaults' => array(
'__NAMESPACE__' => 'X\App',
'controller' => 'Index',
'action' => 'index',
),
'may_terminate' => true,
'child_routes' => array(
'example' => array(
'type' => 'Zend\Mvc\Router\Http\Segment',
'options' => array(
'route' => '/example[:/data]',
'defaults' => array(
'action' => 'example',
),
),
),
),
),
),
),
しかし、それはこのようにしか機能しません:
'router' => array(
'routes' => array(
'app' => array(
'type' => 'Zend\Mvc\Router\Http\Segment',
'options' => array(
'route' => '[/:info]/app',
'defaults' => array(
'__NAMESPACE__' => 'X\App',
'controller' => 'Index',
'action' => 'index',
),
),
),
'app.example' => array(
'type' => 'Zend\Mvc\Router\Http\Segment',
'options' => array(
'route' => '[/:info]/app/example[/:data]',
'defaults' => array(
'__NAMESPACE__' => 'X\App',
'controller' => 'Index',
'action' => 'example',
),
),
),
),
..誰かが私が間違っているかもしれないことを知っています..?