The straightforward wildcarding didn't seem to work (it matched against a literal wildcard). Just an FYI for others, I guess .. :)

Adam Hardy wrote:



Hi Brice,
wasn't long before you came back! I was holding out thinking someone else might have a more intuitive solution than mine, but whatever, in your position I write my own taglib based on the html link taglib & add in the locale to the URL in that.


As for the action mappings, I think you're going to have to test it to see if you can use patterns. The struts gurus seem to be keeping their heads down, but maybe one of them will chime in.

Adam

On 10/21/2003 05:40 PM Ruth, Brice wrote:

Greetings.

As per my previous thread on the best way to create a URL structure like:

http://domain/us/whatever
http://domain/de/whatever
etc.

I've implemented the recommendations I received and now have a Filter listening to each request and setting the locale appropriately based on the country code specified in the URL. Working great :) I also have the .jsp I'm working with mapped to an action with a path like /us/index.do.

Now, within this index page, I have links in my navigation, being generated by the Struts HTML tags (html:link) - how would I best go about incorporating the country URL prefix (/us/, /de/, /fr/, etc.) without manually having to insert something like <bean:write name="locale" property="country"/> - also, instead of setting up an action for each .jsp, for each language (/us/index.do; /de/index.do; /us/crafts/crafts.do; /de/crafts/crafts.do; etc.) - what's a better way of doing this? Can I create an action using org.apache.struts.actions.ForwardAction that uses a wildcard? So something like /*/index.do would have a parameter of /index.jsp and /*/crafts/crafts.do would have a parameter of /crafts/crafts.jsp.

I'm looking for guidance - best way of accomplishing my goals of code-reuse, ease-of-maintenance, as well as being able to provide the flexibility in URL naming that marketing would like to see.

Thanks,
Brice




-- Brice D. Ruth Sr. IT Analyst Fiskars Brands, Inc.



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to