Routes with parameters ordered differently

Hi, i’m trying to setup a custom route and having some trouble.

In various resources i’ve seen plenty of examples of how to do something
along the lines of:

map.connect “foo/bar/:a/:b/:c”,
:controller => “foo”,
:action => “bar”,

(and :a,:b and :c get mapped to params[])

what i’d like to do is make a mapping of the form

map.connect “:foo/:controller/:action/:id”

i’d like to do something like this so people can, say, choose a locale
in the url as the param[:foo] (like

is that possible? i tried adding the route:

map.connect “:foo/:controller/:action/:id”

and when i try to go to an address like the one i specified, it returns
that no route matches.

I’ve seen other posts in the archives that suggest this should work, but
maybe there’s something additional that needs to be done?

any help is greatly appreciated.