Named parameters (such as "module", "controller" and "action" in the "default" route) should not be affected by the ksort, but anything that is handled by "*" should (in your case, the name1 and name2 keys). Again, I didn't test the code, but if it doesn't work that way I'd be surprised.
-- *Hector Virgen* Sr. Web Developer Walt Disney Parks and Resorts Online http://www.virgentech.com On Wed, Oct 20, 2010 at 11:48 AM, Fozzyuw <[email protected]> wrote: > > Hi Hector, > > Thanks for the tip about helpers. > > One item of note, ksorting doesn't actually do anything when passing it to: > "$router->assemble($urlOptions, $name, $reset, $encode);" > > If that doesn't make sense, here's the thing, the URL helper code is simply > this: > > ---- > $router = Zend_Controller_Front::getInstance()->getRouter(); > return $router->assemble($urlOptions, $name, $reset, $encode); > ---- > > tossing a ksort between them doesn't effect the order in which the > $router->assemble() generates the URL. I've just cracked open > "/Zend/Controller/Router/Route.php" to see how the assemble() function > works, but there's a bit more going on in there in terms of having logic > for > handling translations and partials, which I'm not familiar with. > > So, I'm trying to digest what's going on there to figure out if there's a > "Zend" way of doing it or if I simply have to create my own URL helper that > generates the URL, and skip trying to use Router->Route. > > > > -- > View this message in context: > http://zend-framework-community.634137.n4.nabble.com/Generating-URL-s-View-Helper-Action-Helper-tp3002936p3004397.html > Sent from the Zend Framework mailing list archive at Nabble.com. >
