Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-29 Thread Alex Rodriguez Lopez
Thanks Zoran for sharing your approach, greatly appreciated, I'm thinking about implementing a similar interceptor, and maybe replace the i18n one so work is done implicitly with only a change in struts.xml and the new interceptor. Em 29-03-2010 02:58, Zoran Avtarovski escreveu: Hi Guys, We

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-29 Thread Denis Cabasson
Hi, We use a simple and empty s:url includeParam=get/ tag to loop back to the current action/url. The only thing you have to look for are those unsafe urls: we don't have any unsafe urls in our application, thanks to an extensive POST then GET approach. Whenever some action is done in the

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-29 Thread Alex Rodriguez Lopez
Great remarks Denis, thanks! Didn't know about includeParams=get... already changed things to use that, works great! Simple and elegant solution, I too think urls like url/delete?id=# should be best avoided. Using your approach (that is, closer to http specs, no deletes using GET method),

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-28 Thread Zoran Avtarovski
Hi Guys, We simplified it for struts to use a simple interceptor. Can¹t show the exact code due to legal crap, but here¹s the overview. In our base action we have a String called requestString, with appropriate getters and setters. We also have a MapString, String of unsafe URL¹s and their safe

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-25 Thread Alex Rodriguez Lopez
Hi Zoran, would you mind sharing the code of this tag? It would be helpful to me, as somehow I've been able to link to the same sction with an empty url tag but unable to retain params. Thanks! Em 24-03-2010 22:42, Zoran Avtarovski escreveu: I wrote a small custom tag which builds the link

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-25 Thread Celinio Fernandes
Thanks.   Could you share that code ? It would be useful and much appreciated. Thanks again.   --- On Wed, 3/24/10, Zoran Avtarovski zo...@sparecreative.com wrote: From: Zoran Avtarovski zo...@sparecreative.com Subject: Re: [Struts 2.1.8.1] Internationalization: how to remain in the current

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-24 Thread Zoran Avtarovski
I wrote a small custom tag which builds the link with the existing action and parameters. This way it just reloads the page. I also included a parameter that wouldn¹t allow the change (a jQuery dialog would give the user feed back) to take place if there might me an issue with system integrity ­

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-21 Thread Paweł Wielgus
Hi, i don't remeber that for sure, but try s:url without action and namespace, i think it might be what You are looking for. Best greetings, Pawel Wielgus. 2010/3/19, Ulf Liedén ulf.lie...@gmail.com: Hi Celinio, personally, I would build a method that gives back the URL of the page you are

[Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-19 Thread Celinio Fernandes
hi, I have a quick and basic question. Regarding internationalization, whenever a user clicks on a link with a flag, i want to change the locale (language) of the web application. That works well with the i18n interceptor. However i always redirect the user to the home page (home.jsp) when i do

Re: [Struts 2.1.8.1] Internationalization: how to remain in the current page ?

2010-03-19 Thread Ulf Liedén
Hi Celinio, personally, I would build a method that gives back the URL of the page you are currently visiting, including all parameters. You put this method in a superclass of all your actions, so that its available everywhere. In the code you decide which locale parameter to set, according to