nested struts2 validation

2010-05-20 Thread Stephen Ince
Hi, I would like to do nested struts2 validation. I have two questions. 1) How do I specify the validation for the following field. Can some point me to some documenation for the expression validation. input type=text name=searchResults[${i}].resource.name .. validation.xml validator

Re: Forms with Multiple Submit buttons (Bug or Expected?)

2010-05-20 Thread RogerV
dcabasson wrote: Why not doing that on the server side, using the s:token approach? That would prevent double submit on the server side. As an aside to this, is there a similair technique for detecting multiple GET requests for the same action? I've got one particular action that

Change form bean properties in JSP

2010-05-20 Thread Manoj Singh
Hi, Is it possible to change the value of form bean properties in JSP Page? If yes, then please let me know. Thanks, Manoj

ActionContext.getContext().getSession() vs. SessionAware injection (about servlet maps)

2010-05-20 Thread Alex Rodriguez Lopez
Hi Struts users! I was wondering, after reading about the ServletConfigInterceptor, if there are differences in obtaining the session map via the method ActionContext.getContext().getSession() or have it injected through SessionAware. The map that I end up with is the same so... why have to

Re: Change form bean properties in JSP

2010-05-20 Thread Robert Graf-Waczenski
Am 20.05.2010 12:50, schrieb Manoj Singh: Hi, Is it possible to change the value of form bean properties in JSP Page? If yes, then please let me know. Thanks, Manoj Yes. - To unsubscribe, e-mail:

Re: Change form bean properties in JSP

2010-05-20 Thread Manoj Singh
Hi, Thanks for your reply. Please let me know how to do it? Thanks, Manoj On Thu, May 20, 2010 at 4:42 PM, Robert Graf-Waczenski r...@lsoft.comwrote: Am 20.05.2010 12:50, schrieb Manoj Singh: Hi, Is it possible to change the value of form bean properties in JSP Page? If yes, then

Re: Change form bean properties in JSP

2010-05-20 Thread Robert Graf-Waczenski
Am 20.05.2010 13:16, schrieb Manoj Singh: Hi, Thanks for your reply. Please let me know how to do it? Thanks, Manoj On Thu, May 20, 2010 at 4:42 PM, Robert Graf-Waczenskir...@lsoft.comwrote: Am 20.05.2010 12:50, schrieb Manoj Singh: Hi, Is it possible to change the value of

Session variable setting

2010-05-20 Thread Pierre BRARD
Hi all, I am implementing a login system with Struts 2. Basically, I have a custom interceptor which checks in session if a particular variable is set. If it is, the user is considered already logged in and if it is not the variable is set in session ( session.setAttribute(connectedUser, user);

Re: ActionContext.getContext().getSession() vs. SessionAware injection (about servlet maps)

2010-05-20 Thread Greg Lindholm
Writing unit tests are significantly easier when you have dependencies injected with the xxxAware Interfaces. On Thu, May 20, 2010 at 7:11 AM, Alex Rodriguez Lopez alo...@flordeutopia.pt wrote: Hi Struts users! I was wondering, after reading about the ServletConfigInterceptor, if there are

Struts Users Mailing List user@struts.apache.org

2010-05-20 Thread Stephen Ince
Hi, I would like to do nested struts2 validation. I have two questions. 1) How do I specify the validation for the following field. Can some point me to some documenation for the expression validation. input type=text name=searchResults[${i}].resource.name .. validation.xml validator

nested struts2 validation

2010-05-20 Thread Stephen Ince
Hi, I would like to do nested struts2 validation. I have two questions. 1) How do I specify the validation for the following field. Can some point me to some documenation for the expression validation. input type=text name=searchResults[${i}].resource.name .. validation.xml validator

Re: Interceptor order

2010-05-20 Thread Andy Law
RogerV wrote: Andy Law wrote: The pertinent code in the interceptor is reproduced below. It does what I expect it to do insofar as it sticks my Stuff object in a place that the JSP can retrieve it using the MAGIC_KEY string. However, if I configure my interceptor stack with this

Re: Interceptor order

2010-05-20 Thread Chris Pratt
You may want to think about using: invocation.getStack().getContext().put(MAGIC_KEY,getStuff()); instead of: invocation.getStack().set(MAGIC_KEY,getStuff()); For the sake of argument, I'm going to assume that MAGIC_KEY is set to the String magic. The first example above makes #magic available

Re: Interceptor order

2010-05-20 Thread Andy Law
Cheers Chris, Chris Pratt wrote: You may want to think about using: invocation.getStack().getContext().put(MAGIC_KEY,getStuff()); instead of: invocation.getStack().set(MAGIC_KEY,getStuff()); For the sake of argument, I'm going to assume that MAGIC_KEY is set to the String magic.

Re: Session variable setting

2010-05-20 Thread Kartik Kumar
I have found that when your interceptor implements SessionAware and puts some key/value pairs in the map, the session attributes are not available to the action even if it implements SessionAware. To get the session attribute, I did something like this: @SuppressWarnings(unchecked) MapObject,

Re: Session variable setting

2010-05-20 Thread Pierre BRARD
Hi, Thank you for your answer. Fortunatly I found the solution to my problem here: http://www.mail-archive.com/user@struts.apache.org/msg71987.html I had to use the Struts 2 session instead of the HttpServletRequest session : // old HttpSession session = request.getSession(); // now Map

Disappearing Labels

2010-05-20 Thread Bhaarat Sharma
We have a weird problem with multiple Struts2 wars deployed on same GlassFish server. These wars share the Xworks.jar file and have their own copy of struts2-core jar files in WEB-INF/lib Problem we are experiencing is that once the server is restarted everything is ok but after couple of hours

Re: Disappearing Labels

2010-05-20 Thread Cimballi
Did you try putting the xworks jar in each project ? I am not sure but I don't think you can share it. Cimballi On Thu, May 20, 2010 at 9:18 PM, Bhaarat Sharma bhaara...@gmail.com wrote: We have a weird problem with multiple Struts2 wars deployed on same GlassFish server.  These wars share

Re: Disappearing Labels

2010-05-20 Thread Bhaarat Sharma
Hi, Have not tried that yet. We can not try that because of this error on glassfish. http://www.mail-archive.com/user@struts.apache.org/msg76893.html having multiple wars in an ear. this causes wars and ears to not get deployed. I fail to understand why this would happen couple hours after the

Re: Disappearing Labels

2010-05-20 Thread Cimballi
I recommend you to try to deploy both applications on separate servers, as the guy did in your link, and see if you still have the problem. For sure the s:text in Struts uses Xworks. Cimballi On Thu, May 20, 2010 at 10:10 PM, Bhaarat Sharma bhaara...@gmail.com wrote: Hi, Have not tried that

Re: Disappearing Labels

2010-05-20 Thread Bhaarat Sharma
Thanks for clarifying. I will try stuff and get back On Thu, May 20, 2010 at 11:24 PM, Cimballi cimba...@cimballi.net wrote: I recommend you to try to deploy both applications on separate servers, as the guy did in your link, and see if you still have the problem. For sure the s:text in