Hi,

in my Struts2 application, I want the user's current language to be part of the URL. For example:

http://localhost:8080/myApp/en/my/namespace/myAction.action (English)
http://localhost:8080/myApp/de/my/namespace/myAction.action (German)

Is there a built-in feature in Struts to implement this?
I am using the convention plugin and the application contains a lot of actions and JSP pages, therefore I looking for way to implement this without changing existing namespaces or JSP pages.
Anyone who have done this before or have any advice on this?

Instead of implementing it with Struts, I could use my reverse proxy (Apache HTTP) to rewrite requests (strip out the language part from the url and turn it into a request parameter). And for the reverse direction, redirects coming from Struts backend must also be rewritten (transform the 'Location' response header into the URL form from above).
Any thoughts or advice on this?

Which one would be the better approach?

Kind regards
Florian

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to