2010年3月3日星期三

Re: [fw-mvc] Re: Changing get parameters to controller/action/param/value/param/value



David Muir schreef:
That would only be necessary if the desired form were actually required.  Zend's default router sees them as being equivalent: /controller/action/param/value /controller/action?param=value  so in both cases $this->getRequest()->getParam('param'); //returns 'value'  However, if you're wanting something like: /search/value   
For this, you only need a custom route. No extra rewrite.
The point in the original post is that for some unknown reason the get url should be consistent with the other urls in the application.
So the question is how can we make /controller/action?param=value appear as /controller/action/param/value
But the more important question, as pointed out by Andreas is "Why?"
 then yes, you'll need to do the rewrite server-side.      

--
Bart McLeod
Space Web
Middenlaan 47
6865 VN Heveadorp
The Netherlands
t +31(0)26 3392952
m 06 51 51 89 71
@ info@spaceweb.nl
www.spaceweb.nl
zce logozce PHP 5 logo zce Zend Framework logo

Bart McLeod is a Zend Certified Engineer.

Click to verify!

没有评论: