How do I access a routed parameter from inside a controller?
问题 This is the route... 'panel-list' => array ( 'type' => 'Segment', 'options' => array ( 'route' => '/panel-list/:pageId[/:action]', 'constraints' => array ( 'pageId' => '[a-z0-9_-]+' ), 'defaults' => array ( 'action' => 'index', 'controller' => 'PanelList', 'site' => null ), ), ), What do I need to put in here.... public function indexAction() { echo ??????? } to echo the pageId? 回答1: In beta5 of zf2 it changed to easier usage so you don't need to remember different syntax for every different