2008年12月5日星期五

[fw-mvc] Re[fw-mvc] dundant action parameters in request object?

Why is $this->_forward in a controller not causing the $request->_params to
update too?

After doing:

class myModule_IndexController extends Zend_Controller_Action {
public function indexAction() {
$this->_forward('list', 'myController');
}
}

I end up having:

Zend_Controller_Request_Http Object [stripped]
(
[_requestUri:protected] => /myModule/
[_params:protected] => Array
(
[module] => <myModule>
[controller] => index [still old]
[action] => index [still old]
)
[_module:protected] => <myModule>
[_controller:protected] => <myController> [new]
[_action:protected] => list [new]
)

Is there a reason to have a disambigous Request object after a forward, or
should I use another approach?

Why do you (Zend_Controller_Router_Rewrite->route ... _setRequestParams)
want to save the action params both in $request->_params and the protected
Request vars ($request->_controller etc)?
--
View this message in context: http://www.nabble.com/Redundant-action-parameters-in-request-object--tp20860284p20860284.html
Sent from the Zend MVC mailing list archive at Nabble.com.

没有评论: