我正在尝试在访问/ account route下的任何页面时实现强制https.我发现这个问题ZF2与https一起使用,它可以...部分工作.我的路线:
'router' => array(
'routes' => array(
'account' => array(
'type' => 'Scheme',
'options' => array(
'route' => '/account',
'scheme' => 'https',
'defaults' => array(
'controller' => 'Account\Controller\Account',
'action' => 'index',
),
),
'may_terminate' => true,
'child_routes' => array(
'default' => array(
'type' => 'Literal',
'options' => array(
'route' => '/',
'defaults' => array(
'controller' => 'Account\Controller\Account',
'action' => 'index',
),
),
),
'signin' => array(
'type' => 'Segment',
'options' => array(
'route' => '/signin[/:type]',
'defaults' …Run Code Online (Sandbox Code Playgroud)