Re: Can Struts Junit plugin be used to test the redirect result of an action

2011-09-24 Thread miguel
On Thu, 2011-09-22 at 10:23 +0200, Maurizio Cucchiara wrote: The reason behind is simple: no browser no redirect. The redirect is sent as http header, so as long as there is no browser to interpret the header there is no way to redirect. You might call by yourself the second action, WDYT?

Re: Can Struts Junit plugin be used to test the redirect result of an action

2011-09-24 Thread Carl Ballantyne
Just a thought but make sure hibernate is sending the sql to the database. Try stepping through your code using the debugger and add relevant logging to be sure. Call flush() if necessary. On Sat, Sep 24, 2011 at 1:18 PM, miguel mig...@almeida.at wrote: On Thu, 2011-09-22 at 10:23 +0200,

i18n language setting

2011-09-24 Thread Debraj Mallick
hi, i need to set language form action, if i set struts.locale = du_NL in struts.properties then dutch will the default language. how can i set language from action, i have tried using session.put(WW_TRANS_I18N_LOCALE, du_NL); and locale = new Locale(du);

Re: i18n language setting

2011-09-24 Thread Carl Ballantyne
I think you can pass request_locale via the URL. So index.action?request_locale=du_NL. I think this will then keep in in the session until you change it. Check out http://struts.apache.org/2.x/docs/faqs.html - localization section. In particular

Re: Unicode Encoding request parameters

2011-09-24 Thread Li Ying
You don't need an extra-filter. The S2 default encoding is UTF-8. The code of S2 filter is: org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter: public void doFilter(..) { .. prepare.setEncodingAndLocale(request, response); .. } and the code of

Re: Is it possible to redirect after a Stream result action has completed?

2011-09-24 Thread Li Ying
I guess you can not do this. Because there should be ONLY ONE HTTP response for every HTTP request. So you can only return a file downlod or a redirect to the client, but not both. If you want to jump to another page after file download, may be you can try JavaScript solution in the client side.