I am generating url addres with zend url helper with additional /query
, as I found
here.
In configuration file I have setup router like that:
'my_name' => array(
'type' => 'segment',
'options' => array(
'route' => '/my_name/:id/some_action[/:id2]',
'constraints' => array(
'id' => '[0-9]+',
'id2' => '[0-9]+',
),
'defaults' => array(
'controller' => 'MyController',
),
),
'may_terminate' => true,
'child_routes' => array(
'query' => array(
'type' => 'Query',
'options' => array(
'defaults' => array(
)
)
),
),
),
I receive generated link, that looks like that:
http://my_address/my_name/:id/some_action/?controller=MyController&limit=1&action=get&offset=2
What I want to do is to remove controller
and action
params, which I din't set, and to display only params provided by myself.
Is there any option to set in in router config? Or maybe there is any other way to get what I want?