variables.framework.routes = [
{ "/product/:id" = "/product/view/id/:id", "/user/:id" = "/user/view/id/:id",
hint = "Display a specific product or user" },
{ "/products" = "/product/list", "/users" = "/user/list" },
{ "/old/url" = "302:/new/url" },
{ "$GET/login" = "/not/authorized", "$POST/login" = "/auth/login" },
{ "*" = "/not/found" }
];--FW/1 on RIAForge: http://fw1.riaforge.org/FW/1 on github: http://github.com/seancorfield/fw1FW/1 on Google Groups: http://groups.google.com/group/framework-one
I don't think there's is One True Way so "whatever works" is going to
be your best solution.
Specifically, most people have one URL structure but switch languages
on the fly for display using traditional i18n solutions based on Java
resource bundles (Google is your friend).
At World Singles, we support over half a dozen languages and we use a
variant of resource bundles - we store the translations in the
database, keyed by locale and a string "key" for each item, so that we
can have a management console for translators to work with (we have a
fairly sophisticated content review / push mechanism). We keep the
same URL structure for all languages.
I can't recall seeing a web site that goes to the trouble of translating URLs.
--
Sean A Corfield -- (904) 302-SEAN
An Architect's View -- http://corfield.org/
World Singles, LLC. -- http://worldsingles.com/
"Perfection is the enemy of the good."
-- Gustave Flaubert, French realist novelist (1821-1880)
Could we have done that with resource bundles? Sure. But our sites
were not static information that was translated once and forgotten.
They were more dynamic. Being able to add and edit translations via a
shared web interface made more sense for us than dealing with text
files because that fit in better with our established workflows.
Sent from my iPhone