Re: ProductCatalog Tree and Session Scope
Hi Dave, Dave Newton pingsite.com> writes: > If the thing you're looking for is already in session why would you want > to access it in an ActionForm? Just display it and capture the form > selections in the ActionForm. This won't work for my example. The ActionForm is needed to set the properties of the tree via an Action. For example I can toggle with an image if the product category shows their children or not. Is it possible to create an ActionForm during the LoginAction, which later can referenced by an actionmapping? Jan > > Jan Michael wrote: > > How Can I access the productgroup catalog in the session context in an > > ActionForm because I want to use the monkeyTree example by Arron Bates to > > display the tree structure. > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: The validwhen validation's treatment of null and empty string
Craig McClanahan wrote: You need to test for both conditions in the latter case, but the particular approach you suggest above is not necessarily going to work. You cannot reliably do "==" tests on strings if you are looking for equality -- you need to use the equals() function instead. Not sure if I communicated this correctly, as I referenced the 'validwhen' only in the subject and didn't refer to it in my message body (just to set the record straight I've been using Java for 6 years, 4 years as a full-time job). I wasn't sure about the expression language that the "validwhen" validator uses. It doesn't look exactly like JSP EL, but in the JSP expression language you can do stuff like: Hey, property is empty. and the test condition will be true if the following is true (in the Java language): ( property == null || property.equals( "" ) ). Although this is only for java.lang.String objects. Collection (List, Set, etc.) objects also work like collection.isEmpty(). BUT, the kind of expressions that the "validwhen" validator takes don't look like JSP EL, nor Java, and as all the examples seem to say stuff like test (property == null) the reference to "null" kind of concerns me, as it's possible for the bean to use the empty string "" in its properties (at least, that's what I use in all my beans, including the reset() methods). - Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: The validwhen validation's treatment of null and empty string
On 6/2/06, Scott Van Wart <[EMAIL PROTECTED]> wrote: If a bean's property is the empty string "", does a test like (property == null) suffice? Or do I have to say ((property == null) or (property == ''))? You need to test for both conditions in the latter case, but the particular approach you suggest above is not necessarily going to work. You cannot reliably do "==" tests on strings if you are looking for equality -- you need to use the equals() function instead. When faced with the kind of test you're trying to do here, I would suggest the following: if ((property == null) || property.equals("")) { ... it is either null or an empty string ... } It is important to do the null test first, because if that test passes, the expression evaluation rules guarantee that the application won't try to evaluate property.equals("") as well. That's a good thing ... because that would generate a null pointer exception if property was indeed null. If you want to learn more about Java basics things like this, I would strongly recommend working your way through the Java Language Tutorial[1]. It has concise introduction to language concepts like this, plus it goes over the basics of using many of the common Java APIs. - Scott Craig [1] http://java.sun.com/docs/books/tutorial/
The validwhen validation's treatment of null and empty string
If a bean's property is the empty string "", does a test like (property == null) suffice? Or do I have to say ((property == null) or (property == ''))? - Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Validation 'depends' attribute order, and 'validwhen'
I've been looking through guides and such online, but I'm not really clear how the validations work. For example, the JavaDoc for org.apache.struts.validator.FieldChecks.validateLong says it returns "true if valid, false otherwise.", but if the checked value can be converted to java.lang.Long, it returns the value itself, rather than Boolean.TRUE or Boolean.FALSE. I want to combine my own pluggable validators with the 'validwhen' validator, but I'm not sure of the order: - When multiple validators are listed in the 'depends' attribute, are all validators called, or are they called in order until one returns Boolean.TRUE or some other value? - Must all validators return Boolean.TRUE, or some other value, or must at least one return this value? Thanks, Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: ProductCatalog Tree and Session Scope
Jan Michael wrote: > How Can I access the productgroup catalog in the session context in an > ActionForm because I want to use the monkeyTree example by Arron Bates to > display the tree structure. > If the thing you're looking for is already in session why would you want to access it in an ActionForm? Just display it and capture the form selections in the ActionForm. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
ProductCatalog Tree and Session Scope
Hello, actually I try to code an eshop using struts and hibernate technologies. I need some help with my product categories. I want to create a tree where the user (customer) can toggle hrough the product categories of the shop. This has already been done via the MonkeyTree tutorials by Arron Bates. When the first user logs into the shop the productgroup catalog is generated via hibernate and additionally put into users session scope and for future uses (users) into the servlet context. How Can I access the productgroup catalog in the session context in an ActionForm because I want to use the monkeyTree example by Arron Bates to display the tree structure. Any help will be appreciated. Thanks, Jan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: wrong direction in validate
You should define separate action mappings for the different pages that use the action with the different input attribute values. -Richard -Original Message- From: Andreas Hartmann [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 1:27 PM To: Struts Users Mailing List Subject: Re: wrong direction in validate Hello Dave, Dave Newton wrote: > Andreas Hartmann wrote: >> How does struts determinate the destination to go to in error >> situation? >> > > If you're letting Struts do the validation it will return to whatever > you have defined as the 'input' attribute in your action mapping, > which you didn't post. If you're doing validation some other way, > impossible to say without more info. The path to the wrong destination is: After getservertyp.jsp (mapping <1>) /pages/eigenschaften-long.jsp (mapping <2>) is loaded. On this page, a click onto "change" leads to /pages/exec.jsp (mapping <3>). If there is a validation error in Eigenschaftenform (mapping <2>), the page /pages/abfrage.jsp (from mapping <4>, which has never been used in this path) is loaded - but this is wrong. It should be /pages/eigenschaften-long.jsp (mapping <2>). Is mapping <4> loaded, because it's the last member of the action-mapping? Could it be, that the attribute path of each action should be unique? A cut of struts-config. It's important to say, that there is more than one page which uses Eigenschaftenform and Eigenschaften. Kind regards, Andreas Hartmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Logic:Iterate & HashMap
Use the name and property attributes in your iterate tag, where "name" is the name of your DTO and "property" is the name of the Map within the DTO. You can have a look at the docs here: http://struts.apache.org/struts-doc-1.2.7/userGuide/struts-logic.html On 6/2/06, Marco Mistroni <[EMAIL PROTECTED]> wrote: Hi all, I m having a problem with logic:iterate I have a Map that contains{String, MyDTO} In my jsp I m writing following code; 0 0 Struts complaints that 'No allocatedQuantity property found on bean 'stock' But it is in my DTO Am I missing something? Thanks and regards marco -Original Message- From: marcus biel (innoWake gmbh) [mailto:[EMAIL PROTECTED] Sent: 01 June 2006 15:50 To: Struts Users Mailing List Subject: Validating in Action? Hi, I got a JSP, form and Action. I want to add 3 values into an database. This is done in my action. The problem: I am using a Service to add the stuff to the db, and when using this service, it throws error messages like "artikel not found" or "project not found". Now I want to display these errors to the user - The problem is I can't do those error validation in my ActionForm, because only after doing the action I will know wether or not it succeeded - so how can I then set the appropiate errormessages and forward to the jsp? Thanks, Marcus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: wrong direction in validate
Hello Dave, Dave Newton wrote: > Andreas Hartmann wrote: >> How does struts determinate the destination to go to in error situation? >> > > If you're letting Struts do the validation it will return to whatever > you have defined as the 'input' attribute in your action mapping, which > you didn't post. If you're doing validation some other way, impossible > to say without more info. The path to the wrong destination is: After getservertyp.jsp (mapping <1>) /pages/eigenschaften-long.jsp (mapping <2>) is loaded. On this page, a click onto "change" leads to /pages/exec.jsp (mapping <3>). If there is a validation error in Eigenschaftenform (mapping <2>), the page /pages/abfrage.jsp (from mapping <4>, which has never been used in this path) is loaded - but this is wrong. It should be /pages/eigenschaften-long.jsp (mapping <2>). Is mapping <4> loaded, because it's the last member of the action-mapping? Could it be, that the attribute path of each action should be unique? A cut of struts-config. It's important to say, that there is more than one page which uses Eigenschaftenform and Eigenschaften. Kind regards, Andreas Hartmann - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Email validation doesn't work
The Struts has built-in e-mail validation, which can be found in the commons-validator.jar. --- Bart Busschots <[EMAIL PROTECTED]> wrote: > Hi, > > Your regular expression on the mask would seem to be > problem. I presume > you want it to match words that contain no = rather > than what you have > at the moment which forces ALL letters to be = which > I'm sure doesn't work. > > The RE you need is: > > ^[^=]+$ > > HTH, Bart. > > marisol wrote: > > Can anybody help me with this? THANKS! > > Marisol. > > > > > > With Struts Validator Framework, the following > mail is valid [EMAIL PROTECTED] > > > > I tried with the following but it doesn't work. > > > > > > key="userRegistration.mailMask" /> > > > > > > mask > > ^[=]*$ > > > > > > > > Anyone knows if there's a bug place or it's me > doing something wrong??? > > > > THANKS! > > Marisol. > > > > > > > > > - > > To unsubscribe, e-mail: > [EMAIL PROTECTED] > > For additional commands, e-mail: > [EMAIL PROTECTED] > > > > > > > > > - > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6
Thanks for clarifying that. While taglib entries aren't required, they can be used, and in troubleshooting a tag library issue it can be important to know whether they are specified in web.xml or loaded automatically from jar files. -Adam -Original Message- From: John R. Dumonceaux [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 12:08 PM To: Struts Users Mailing List Subject: RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 For JSP 1.3 and higher you don't need the taglib entries in the web.xml. The directive in the JSP file is all you need. John Dumonceaux "Samere, Adam J" <[EMAIL PROTECTED]> 06/02/2006 10:36 AM Please respond to "Struts Users Mailing List" To "Struts Users Mailing List" cc Subject RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 I doubt that the include is not working. What version of JSTL are you using? Do you have taglib entries in web.xml? Can you explain "JSTL stopped working" a little more extensively? -Original Message- From: Rafael [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 11:01 AM To: Struts Users Mailing List Subject: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 Hi Guys, I've an application that uses Struts and Tiles, this application was running on WebSphere 5.1 for almost 3 years but now when we moved to WAS6 JSTL stopped working. Let me give an example: we've a jsp page called taglibs.jsp, in this jsp page we've all the struts, jstl taglibrary imports. So, when we need struts or JSTL in another JSP page we just include this taglibs.jsp. Using -> <%@ include file="/jsp/taglibs.jsp" %> , seems that WAS6 container support JSP 2.0 and somehow this caused the include directive to stop working. I found a lot of messages in Forums and after I read the JSP 2.0 spec, I decided to set encoding to each page. Isn't worked because actually include directive includes content like-> Content but don't include taglib directives like the one below. <%@ taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> Any ideias ? Thanks !! -Rafael T Icibaci - The information contained in this message may be privileged, confidential, and protected from disclosure. If the reader of this message is not the intended recipient, or any employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer. Thank you. Paychex, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6
For JSP 1.3 and higher you don't need the taglib entries in the web.xml. The directive in the JSP file is all you need. John Dumonceaux "Samere, Adam J" <[EMAIL PROTECTED]> 06/02/2006 10:36 AM Please respond to "Struts Users Mailing List" To "Struts Users Mailing List" cc Subject RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 I doubt that the include is not working. What version of JSTL are you using? Do you have taglib entries in web.xml? Can you explain "JSTL stopped working" a little more extensively? -Original Message- From: Rafael [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 11:01 AM To: Struts Users Mailing List Subject: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 Hi Guys, I've an application that uses Struts and Tiles, this application was running on WebSphere 5.1 for almost 3 years but now when we moved to WAS6 JSTL stopped working. Let me give an example: we've a jsp page called taglibs.jsp, in this jsp page we've all the struts, jstl taglibrary imports. So, when we need struts or JSTL in another JSP page we just include this taglibs.jsp. Using -> <%@ include file="/jsp/taglibs.jsp" %> , seems that WAS6 container support JSP 2.0 and somehow this caused the include directive to stop working. I found a lot of messages in Forums and after I read the JSP 2.0 spec, I decided to set encoding to each page. Isn't worked because actually include directive includes content like-> Content but don't include taglib directives like the one below. <%@ taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> Any ideias ? Thanks !! -Rafael T Icibaci - The information contained in this message may be privileged, confidential, and protected from disclosure. If the reader of this message is not the intended recipient, or any employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer. Thank you. Paychex, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [Struts + Tiles] JSTL problem on WebSphere Application Server 6
I doubt that the include is not working. What version of JSTL are you using? Do you have taglib entries in web.xml? Can you explain "JSTL stopped working" a little more extensively? -Original Message- From: Rafael [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 11:01 AM To: Struts Users Mailing List Subject: [Struts + Tiles] JSTL problem on WebSphere Application Server 6 Hi Guys, I've an application that uses Struts and Tiles, this application was running on WebSphere 5.1 for almost 3 years but now when we moved to WAS6 JSTL stopped working. Let me give an example: we've a jsp page called taglibs.jsp, in this jsp page we've all the struts, jstl taglibrary imports. So, when we need struts or JSTL in another JSP page we just include this taglibs.jsp. Using -> <%@ include file="/jsp/taglibs.jsp" %> , seems that WAS6 container support JSP 2.0 and somehow this caused the include directive to stop working. I found a lot of messages in Forums and after I read the JSP 2.0 spec, I decided to set encoding to each page. Isn't worked because actually include directive includes content like-> Content but don't include taglib directives like the one below. <%@ taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> Any ideias ? Thanks !! -Rafael T Icibaci - The information contained in this message may be privileged, confidential, and protected from disclosure. If the reader of this message is not the intended recipient, or any employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer. Thank you. Paychex, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: wrong direction in validate
Dave Newton wrote: Andreas Hartmann wrote: How does struts determinate the destination to go to in error situation? If you're letting Struts do the validation it will return to whatever you have defined as the 'input' attribute in your action mapping, which you didn't post. If you're doing validation some other way, impossible to say without more info. Is it possible to define the 'input' page on the fly, so multiple pages can use the same forward with validation? Thanks, Scott - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Struts + Tiles] JSTL problem on WebSphere Application Server 6
Hi Guys, I've an application that uses Struts and Tiles, this application was running on WebSphere 5.1 for almost 3 years but now when we moved to WAS6 JSTL stopped working. Let me give an example: we've a jsp page called taglibs.jsp, in this jsp page we've all the struts, jstl taglibrary imports. So, when we need struts or JSTL in another JSP page we just include this taglibs.jsp. Using -> <%@ include file="/jsp/taglibs.jsp" %> , seems that WAS6 container support JSP 2.0 and somehow this caused the include directive to stop working. I found a lot of messages in Forums and after I read the JSP 2.0 spec, I decided to set encoding to each page. Isn't worked because actually include directive includes content like-> Content but don't include taglib directives like the one below. <%@ taglib uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> Any ideias ? Thanks !! -Rafael T Icibaci
RE: Validation with validwhen
No, js support for validwhen is not provided. You can tell by looking at the validation-rules.xml file, which does not have a jsFunction attribute defined on the "validwhen" validator element. -Original Message- From: Cassio Pereira [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 10:08 AM To: user@struts.apache.org Subject: Validation with validwhen Hi all. Simple question. Does "validwhen" works client side? Regards -- Cassio Santos Pereira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - The information contained in this message may be privileged, confidential, and protected from disclosure. If the reader of this message is not the intended recipient, or any employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by replying to the message and deleting it from your computer. Thank you. Paychex, Inc. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Validation with validwhen
Hi all. Simple question. Does "validwhen" works client side? Regards -- Cassio Santos Pereira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Email validation doesn't work
Hi, Your regular expression on the mask would seem to be problem. I presume you want it to match words that contain no = rather than what you have at the moment which forces ALL letters to be = which I'm sure doesn't work. The RE you need is: ^[^=]+$ HTH, Bart. marisol wrote: Can anybody help me with this? THANKS! Marisol. With Struts Validator Framework, the following mail is valid [EMAIL PROTECTED] I tried with the following but it doesn't work. mask ^[=]*$ Anyone knows if there's a bug place or it's me doing something wrong??? THANKS! Marisol. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Struts Best Practices
There's a presentation you can review here, but it's not an actual article. * http://opensource.atlassian.com/confluence/oss/pages/viewpageattachments.action?pageId=829 -- HTH, Ted. * http://www.husted.com/struts/ On 6/2/06, Hanmay Udgiri <[EMAIL PROTECTED]> wrote: Hi Can anybody have any articles for struts best practices?? Will be of great help. -- Thanks and Regards Hanmayya Udgiri - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cancel button:NOT work
M.Liang Liu wrote: > Thank you,sir. Just for completeness, Wendy's a she ;) Darn lack of gender-specific pronouns... My taiji teacher always referred to me as "her" when talking about me in class. Took like three years to finally get her to stop. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: dispatch action error
Perhaps two requests are being made: one for the anchor, one for the form submit. The anchor would send the method value, the form would not (unless you have an input named method defined on the form). -Original Message- From: Shoukat, Faisal [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 8:16 AM To: Struts Users Mailing List Subject: RE: dispatch action error I did some debugging on the getMethod() and when I submit the form the request.getParameter() first time returns '' then in the same request changeStatus parameter is found. So its not that the form is not passing the parameter because it does, the issue I don't understand is why would it pass '' initially then in the same request it finds the correct parameter Any pointers -Original Message- From: Samere, Adam J [mailto:[EMAIL PROTECTED] Sent: 02 June 2006 13:09 To: Struts Users Mailing List Subject: RE: dispatch action error I don't think your method param is being passed when the form is submitted. You should probably make the parameters you are passing in the query string hidden fields on the form you are submitting. If you need to dynamically set the method parameter you can then do so in the onclick event of the anchor element. [Submit] -Adam -Original Message- From: Shoukat, Faisal [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 5:35 AM To: Struts Users Mailing List Subject: dispatch action error Hi Guys, I am after some advice with the following: I am submitting a form which has the value as selected in a drop down. >From my struts config.xml it forwards to the correct dispatch action class method. And does the processing within that method. However just before returning to the next jsp it throws the logging exception recorded below where it states that I have tried to call a dispatch action class with a parameter of ''. I don't understand why it makes this second call. I submit the form with the following link: ?method=changeStatus&applicantId= " onclick="javascript:document.forms.applicationDetailsForm.submit();retur n false;">[Submit] I have tried it with return false and without it. Can anybody advise on this? Thanks 10:08:12,253 DEBUG [LoginBarFilter] In doFilter() for request: [EMAIL PROTECTED] 10:08:12,253 DEBUG [LoginBarFilter] checking access level 10:08:12,253 INFO [LoginBarFilter] Level determined as SAVSUB 10:08:12,253 INFO [LoginBarFilter] storing access level SAVSUB to session with key access 10:08:12,253 INFO [LoginBarFilter] setting module name for css to AYRECRUIT 10:08:12,269 DEBUG [LoginBarFilter] Branding URL from DB = 10:08:12,269 DEBUG [ModuleUtils] Get module name for path /web/applicationDetails.do 10:08:12,269 DEBUG [ModuleUtils] Module name found: default 10:08:12,269 DEBUG [RequestProcessor] Processing a 'GET' for path '/web/applicationDetails' 10:08:12,269 DEBUG [RequestUtils] Looking for ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestUtils] Can recycle existing ActionForm instance of type 'abc.forms.ApplicationDetailsForm'?: true 10:08:12,269 DEBUG [RequestUtils] --> [EMAIL PROTECTED] 10:08:12,269 DEBUG [RequestProcessor] Storing ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestProcessor] Populating bean properties from this request 10:08:12,269 DEBUG [RequestProcessor] Looking for Action instance for class abc.actions.ApplicationDetailsAction 10:08:12,269 DEBUG [RequestProcessor] Returning existing Action instance 10:08:12,269 ERROR [DispatchAction] Action[/web/applicationDetails] does not contain method named '' java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.j ava: 262) java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194 ) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestPr oces sor.java:419) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 224) at org.apache.struts.actions.DispatchActio
RE: dispatch action error
I did some debugging on the getMethod() and when I submit the form the request.getParameter() first time returns '' then in the same request changeStatus parameter is found. So its not that the form is not passing the parameter because it does, the issue I don't understand is why would it pass '' initially then in the same request it finds the correct parameter Any pointers -Original Message- From: Samere, Adam J [mailto:[EMAIL PROTECTED] Sent: 02 June 2006 13:09 To: Struts Users Mailing List Subject: RE: dispatch action error I don't think your method param is being passed when the form is submitted. You should probably make the parameters you are passing in the query string hidden fields on the form you are submitting. If you need to dynamically set the method parameter you can then do so in the onclick event of the anchor element. [Submit] -Adam -Original Message- From: Shoukat, Faisal [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 5:35 AM To: Struts Users Mailing List Subject: dispatch action error Hi Guys, I am after some advice with the following: I am submitting a form which has the value as selected in a drop down. >From my struts config.xml it forwards to the correct dispatch action class method. And does the processing within that method. However just before returning to the next jsp it throws the logging exception recorded below where it states that I have tried to call a dispatch action class with a parameter of ''. I don't understand why it makes this second call. I submit the form with the following link: ?method=changeStatus&applicantId= " onclick="javascript:document.forms.applicationDetailsForm.submit();retur n false;">[Submit] I have tried it with return false and without it. Can anybody advise on this? Thanks 10:08:12,253 DEBUG [LoginBarFilter] In doFilter() for request: [EMAIL PROTECTED] 10:08:12,253 DEBUG [LoginBarFilter] checking access level 10:08:12,253 INFO [LoginBarFilter] Level determined as SAVSUB 10:08:12,253 INFO [LoginBarFilter] storing access level SAVSUB to session with key access 10:08:12,253 INFO [LoginBarFilter] setting module name for css to AYRECRUIT 10:08:12,269 DEBUG [LoginBarFilter] Branding URL from DB = 10:08:12,269 DEBUG [ModuleUtils] Get module name for path /web/applicationDetails.do 10:08:12,269 DEBUG [ModuleUtils] Module name found: default 10:08:12,269 DEBUG [RequestProcessor] Processing a 'GET' for path '/web/applicationDetails' 10:08:12,269 DEBUG [RequestUtils] Looking for ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestUtils] Can recycle existing ActionForm instance of type 'abc.forms.ApplicationDetailsForm'?: true 10:08:12,269 DEBUG [RequestUtils] --> [EMAIL PROTECTED] 10:08:12,269 DEBUG [RequestProcessor] Storing ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestProcessor] Populating bean properties from this request 10:08:12,269 DEBUG [RequestProcessor] Looking for Action instance for class abc.actions.ApplicationDetailsAction 10:08:12,269 DEBUG [RequestProcessor] Returning existing Action instance 10:08:12,269 ERROR [DispatchAction] Action[/web/applicationDetails] does not contain method named '' java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.j ava: 262) java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194 ) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestPr oces sor.java:419) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 224) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.j ava: 262) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194 ) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at org.apache.struts.action.RequestProcessor.processActionP
Re: wrong direction in validate
Andreas Hartmann wrote: > How does struts determinate the destination to go to in error situation? > If you're letting Struts do the validation it will return to whatever you have defined as the 'input' attribute in your action mapping, which you didn't post. If you're doing validation some other way, impossible to say without more info. Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: dispatch action error
I don't think your method param is being passed when the form is submitted. You should probably make the parameters you are passing in the query string hidden fields on the form you are submitting. If you need to dynamically set the method parameter you can then do so in the onclick event of the anchor element. [Submit] -Adam -Original Message- From: Shoukat, Faisal [mailto:[EMAIL PROTECTED] Sent: Friday, June 02, 2006 5:35 AM To: Struts Users Mailing List Subject: dispatch action error Hi Guys, I am after some advice with the following: I am submitting a form which has the value as selected in a drop down. From my struts config.xml it forwards to the correct dispatch action class method. And does the processing within that method. However just before returning to the next jsp it throws the logging exception recorded below where it states that I have tried to call a dispatch action class with a parameter of ''. I don't understand why it makes this second call. I submit the form with the following link: ?method=changeStatus&applicantId= " onclick="javascript:document.forms.applicationDetailsForm.submit();retur n false;">[Submit] I have tried it with return false and without it. Can anybody advise on this? Thanks 10:08:12,253 DEBUG [LoginBarFilter] In doFilter() for request: [EMAIL PROTECTED] 10:08:12,253 DEBUG [LoginBarFilter] checking access level 10:08:12,253 INFO [LoginBarFilter] Level determined as SAVSUB 10:08:12,253 INFO [LoginBarFilter] storing access level SAVSUB to session with key access 10:08:12,253 INFO [LoginBarFilter] setting module name for css to AYRECRUIT 10:08:12,269 DEBUG [LoginBarFilter] Branding URL from DB = 10:08:12,269 DEBUG [ModuleUtils] Get module name for path /web/applicationDetails.do 10:08:12,269 DEBUG [ModuleUtils] Module name found: default 10:08:12,269 DEBUG [RequestProcessor] Processing a 'GET' for path '/web/applicationDetails' 10:08:12,269 DEBUG [RequestUtils] Looking for ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestUtils] Can recycle existing ActionForm instance of type 'abc.forms.ApplicationDetailsForm'?: true 10:08:12,269 DEBUG [RequestUtils] --> [EMAIL PROTECTED] 10:08:12,269 DEBUG [RequestProcessor] Storing ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestProcessor] Populating bean properties from this request 10:08:12,269 DEBUG [RequestProcessor] Looking for Action instance for class abc.actions.ApplicationDetailsAction 10:08:12,269 DEBUG [RequestProcessor] Returning existing Action instance 10:08:12,269 ERROR [DispatchAction] Action[/web/applicationDetails] does not contain method named '' java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.j ava: 262) java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMap ping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194 ) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestPr oces sor.java:419) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:3 22) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 224) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.j ava: 262) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194 ) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestPr oces sor.java:419) at javax.servlet.http.HttpServlet.service(HttpServlet.java:192) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 224) at javax.servlet.http.HttpServlet.service(HttpServlet.java:306) at javax.servlet.http.HttpServlet.service(HttpServlet.java:333) at com.evermind._ha.doFilter(Unknown Source) at com.abc.resourcelink.common.LoginBarFilter.doFilter(LoginBarFilter.java: 92) at com.evermind._csb._
Email validation doesn't work
Can anybody help me with this? THANKS! Marisol. With Struts Validator Framework, the following mail is valid [EMAIL PROTECTED] I tried with the following but it doesn't work. mask ^[=]*$ Anyone knows if there's a bug place or it's me doing something wrong??? THANKS! Marisol. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Java Exams Web site
any answer? Regards, On 5/29/06, Ahmed Hashim <[EMAIL PROTECTED]> wrote: Dear All, From 2 months, I found a web site offer Free Java Exams and Exams for frameworks like Struts and all technologies like EJB, JSF. There are 2 types of exam, Demo and Real. To go through the real exam, you must have points. To get points, you must contribute by adding questions in any exam. Unfortunately, i forgot the address of this website. Do any body know this website? Regards, Ahmed Hashim http://www.egjug.org -- In Life, it doesn't matter who you are, but whether someone appreciates you for what you are, accepts you and loves you unconditionally. A Real Friend ( Friendship ) is one who walks in when the rest of the world walks away. -- In Life, it doesn't matter who you are, but whether someone appreciates you for what you are, accepts you and loves you unconditionally. A Real Friend ( Friendship ) is one who walks in when the rest of the world walks away.
Non-initializing Struts Action Servlet, Digester and xercesImpl
Hi, Referring to (FW: [jira] Commented: (MYFACES-1170) Application can not startif xercesImpl-2.7.1.jar is present and http://www.mail-archive.com/dev@myfaces.apache.org/msg12153.html I wonder if anyone else had the problem described below: Deploying a Struts 1.2.9 web application on Oracle 10gR2 iAS, WebSphere 5.1 and WebLogic (all servlet 2.3)using Struts v.1.2.8, Digester >= v.1.5 and Xerces > v.2.0.2 causes the ActionServlet not to initialize. Reverting either Digester to < 1.5 or xercesImpl to < 2.0.2 respectively, removes the problem but is not a completely satisfactory solution. We tried to download the nightly build of Digester from 2006-05-23, but the problem with non-initializing ActionServlet for Struts 1.2.8, XercesImpl-2.8.0 and and Digester still remains. This is the exception trace: 503 Service Unavailable javax.servlet.UnavailableException at org.apache.struts.action.ActionServlet.init(ActionServlet.java:368) t javax.servlet.GenericServlet.init(GenericServlet.java:258) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.loadServlet(HttpApplication.java:2354) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.findServlet(HttpApplication.java:4795) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:2821) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:680) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:224) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.AJPRequestHandler.run(AJPRequestHandler.java:133) at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].util.ReleasableResourcePooledExecutor $MyWorker.run(ReleasableResourcePooledExecutor.java:192) at java.lang.Thread.run(Thread.java:534) -Original Message- From: Simon Kitching [mailto:[EMAIL PROTECTED] Sent: 24. mai 2006 07:33 To: Hauknes Gudny Subject: Re: FW: [jira] Commented: (MYFACES-1170) Application can not startif xercesImpl-2.7.1.jar is present Hi Gudny, That XercesParser issue is not going to be fixed. The whole parser configuration stuff was a bad idea in the first place, and is basically impossible to get right at the Digester level. Instead, code should configure a parser however it wants and pass that parser in to the Digester. So that means fixing whatever code is using Digester. It's not clear from your email whether that's Struts or Oracle. In future, I recommend sending emails like this to the commons-user list, so that other people may also reply. Regards, Simon On Tue, 2006-05-23 at 13:25 +0200, Hauknes Gudny wrote: > Hi, > Any news on this? > We may have ran into a related problem: > >(...) > Also, from the Digester CVS, it seems that no patch on the broken > XercesParser has been delivered, is that so: > http://svn.apache.org/viewvc/jakarta/commons/proper/digester/trunk/src/java/org/apache/commons/digester/parser/XercesParser.java?r1=155412&r2=385710 > ? > Disclaimer: This message and any attachments thereto are intended solely for the addressed recipient(s) and may contain confidential information. If you are not the intended recipient, please notify the sender by reply e-mail and delete the e-mail (including any attachments thereto) without producing, distributing or retaining any copies thereof. Any review, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient(s) is prohibited. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Console
hi! I have a problem in running struts console. The application just not starts up. i use windows 2000. it used to work fine till yesterday but from the last 10 hours it is not working. i tried to reboot, reinstall, reinstall jre but to no avail. the struts console window appears in the taskbar but it does not start up. please help me. i am in a fix. Abhimanyu Koul FinEng Solutions (P) Ltd. Dani Compound, 158, Vidyanagari Marg, Kalina, Santacruz (East), Mumbai - 400 098 Mobile : +91 9819510090
dispatch action error
Hi Guys, I am after some advice with the following: I am submitting a form which has the value as selected in a drop down. From my struts config.xml it forwards to the correct dispatch action class method. And does the processing within that method. However just before returning to the next jsp it throws the logging exception recorded below where it states that I have tried to call a dispatch action class with a parameter of ''. I don't understand why it makes this second call. I submit the form with the following link: ?method=changeStatus&applicantId= " onclick="javascript:document.forms.applicationDetailsForm.submit();return false;">[Submit] I have tried it with return false and without it. Can anybody advise on this? Thanks 10:08:12,253 DEBUG [LoginBarFilter] In doFilter() for request: [EMAIL PROTECTED] 10:08:12,253 DEBUG [LoginBarFilter] checking access level 10:08:12,253 INFO [LoginBarFilter] Level determined as SAVSUB 10:08:12,253 INFO [LoginBarFilter] storing access level SAVSUB to session with key access 10:08:12,253 INFO [LoginBarFilter] setting module name for css to AYRECRUIT 10:08:12,269 DEBUG [LoginBarFilter] Branding URL from DB = 10:08:12,269 DEBUG [ModuleUtils] Get module name for path /web/applicationDetails.do 10:08:12,269 DEBUG [ModuleUtils] Module name found: default 10:08:12,269 DEBUG [RequestProcessor] Processing a 'GET' for path '/web/applicationDetails' 10:08:12,269 DEBUG [RequestUtils] Looking for ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestUtils] Can recycle existing ActionForm instance of type 'abc.forms.ApplicationDetailsForm'?: true 10:08:12,269 DEBUG [RequestUtils] --> [EMAIL PROTECTED] 10:08:12,269 DEBUG [RequestProcessor] Storing ActionForm bean instance in scope 'session' under attribute key 'applicationDetailsForm' 10:08:12,269 DEBUG [RequestProcessor] Populating bean properties from this request 10:08:12,269 DEBUG [RequestProcessor] Looking for Action instance for class abc.actions.ApplicationDetailsAction 10:08:12,269 DEBUG [RequestProcessor] Returning existing Action instance 10:08:12,269 ERROR [DispatchAction] Action[/web/applicationDetails] does not contain method named '' java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMapping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:322) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java: 262) java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMapping , org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194) at java.lang.Class.getMethod(Class.java:986) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProces sor.java:419) at org.apache.struts.actions.DispatchAction.getMethod(DispatchAction.java:322) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224) at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java: 262) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194) at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414) at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProces sor.java:419) at javax.servlet.http.HttpServlet.service(HttpServlet.java:192) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224) at javax.servlet.http.HttpServlet.service(HttpServlet.java:306) at javax.servlet.http.HttpServlet.service(HttpServlet.java:333) at com.evermind._ha.doFilter(Unknown Source) at com.abc.resourcelink.common.LoginBarFilter.doFilter(LoginBarFilter.java:92) at com.evermind._csb._pvd(Unknown Source) at com.evermind._csb._boc(Unknown Source) at com.evermind._ax._lsc(Unknown Source) at com.evermind._ax._uab(Unknown Source) at com.evermind._bf.run(Unknown Source) 10:08:12,269 ERROR [SLCExceptionHandler] SLC Exception Handler called with class java.lang.NoSuchMethodException 10:08:12,269 FATAL [SLCExceptionHandler] java.lang.NoSuchMethodException: abc.actions.ApplicationDetailsAction.(org.apache.struts.action.ActionMapping , org.apache.struts.action.ActionForm,
Logic:Iterate & HashMap
Hi all, I m having a problem with logic:iterate I have a Map that contains{String, MyDTO} In my jsp I m writing following code; 0 0 Struts complaints that 'No allocatedQuantity property found on bean 'stock' But it is in my DTO Am I missing something? Thanks and regards marco -Original Message- From: marcus biel (innoWake gmbh) [mailto:[EMAIL PROTECTED] Sent: 01 June 2006 15:50 To: Struts Users Mailing List Subject: Validating in Action? Hi, I got a JSP, form and Action. I want to add 3 values into an database. This is done in my action. The problem: I am using a Service to add the stuff to the db, and when using this service, it throws error messages like "artikel not found" or "project not found". Now I want to display these errors to the user - The problem is I can't do those error validation in my ActionForm, because only after doing the action I will know wether or not it succeeded - so how can I then set the appropiate errormessages and forward to the jsp? Thanks, Marcus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Global forwards don't support Tiles definitions?
not sure if this is what you want but this one should work: global forward is defined as, fot example: the ".authorizationError" is defined as a Tile: in your action class, you can do this: return mapping.findForward("authorizationError");
Struts Best Practices
Hi Can anybody have any articles for struts best practices?? Will be of great help. -- Thanks and Regards Hanmayya Udgiri