是否可以使用
将POST / GET参数发送到控制器中$this->_forward("/url/here");
答案 0 :(得分:2)
public function fooAction()
{
// forward to another action in the current controller and module:
$this->_forward('bar', null, null, array('baz' => 'bogus'));
}
public function barAction()
{
// forward to an action in another controller:
// FooController::bazAction(),
// in the current module:
$this->_forward('baz', 'foo', null, array('baz' => 'bogus'));
}
public function bazAction()
{
// forward to an action in another controller in another module,
// Foo_BarController::bazAction():
$this->_forward('baz', 'bar', 'foo', array('baz' => 'bogus'));
}
根据手册,你可以用数组发送参数,应该是最后一个参数。