Re: pb using validator with struts1.2.9

2006-07-27 Thread Jeremy Jardin
Ok it works well now ! I didn't know that the validwhen rule was server-side validation.. so I expected to have js popup with the 'validwhen' worries .. It' s ok now thanks a lot for you help. ++ On 7/26/06, Adam Gordon <[EMAIL PROTECTED]> wrote: Jeremy- Sorry you're still having problems.

Re: pb using validator with struts1.2.9

2006-07-26 Thread Adam Gordon
Jeremy- Sorry you're still having problems. Regarding the missing resource, I think it will either print out "null" (in the error-printing JSP code) or throw an exception if it cannot find a message resource so you should at least see something like that. Are you sure validation is even bein

Re: pb using validator with struts1.2.9

2006-07-26 Thread Jeremy Jardin
If I have a look at my generatated js source code, I can't see the validwhen method : function validateStartSubscriptionForm(form) { if (bCancel) { return true; } else { var formValidationResult; formValidationResult = validateRequired(form) && va

Re: pb using validator with struts1.2.9

2006-07-26 Thread Jeremy Jardin
I've change my validwhen rule into this : test (((subscriptionType !=1)AND(*THIS*!=null)) OR (subscriptionType==1)) but it still

Re: pb using validator with struts1.2.9

2006-07-26 Thread Jeremy Jardin
-Irwan, Thank you myuch for your help, but I don't have any problem regarding those show/hide method ! I'm just wondering if the fact of removing some fields in the form could be at the origin of my validation matters ?? On 7/26/06, Irwan Nurwandi <[EMAIL PROTECTED]> wrote: Dear Jeremy ..

Re: pb using validator with struts1.2.9

2006-07-26 Thread Irwan Nurwandi
Dear Jeremy .. According to your code below, it seems that for the first time the jsp page load you're initialiaze the var variable into string "1". So the three object you've mention before automatically will not visible. try this and hope you can learn more .. Modify your jsp code <% String

Re: pb using validator with struts1.2.9

2006-07-26 Thread Jeremy Jardin
hum, I mean my jsp is built dynamically.. so when my select box is set to "1", my jsp is made with 4 fields. But if my select box is set to "2", "3" or "4". my JSP page is made with 3 new fields. And I think that "hide" means present but not visible.. and "not display" means not present in the p

Re: pb using validator with struts1.2.9

2006-07-26 Thread Irwan Nurwandi
Dear Jeremy .. what do you mean with "should I "hide" fields rather than "not display" fields.. ??", "hide" and "not display" are the same things isn't it :-) if you're expect the validwhen to manage hide and unhide HTML object, validwhen couldn't do such a thing. = Taken from struts doc :

Re: pb using validator with struts1.2.9

2006-07-26 Thread Jeremy Jardin
-Adam, first, thanks for all those explications. but I've still a problem with my validator using 'validwhen'. I've seen first, that I don't have any "errors.validwhen = mymessage" line in my messageResource file ? I guess I need to add it and I did it. Otherwise, I've now clearly understood (I

Re: pb using validator with struts1.2.9

2006-07-25 Thread Adam Gordon
Jeremy- Ok, sanity-check time. Make sure your field names are all spelled correctly. Also, are any errors being output to the form? I had errors displaying and it turned out that the validator was doing exactly what I was asking it to do and the problem was that I just didn't understand th

Re: pb using validator with struts1.2.9

2006-07-25 Thread Jeremy Jardin
-Adam, I've just changed my conf like that : test (subscriptionType>=1) but, it still does not work.. On 7/25/06, Adam Gordon <[EMAIL PROTECTED]> wrote: Jeremy- At first glance, I t

Re: pb using validator with struts1.2.9

2006-07-25 Thread Adam Gordon
Jeremy- At first glance, I think you need to modify your parenthesis. Per the Validation docs at http://struts.apache.org/1.2.9/userGuide/dev_validator.html, only two items may be joined with "and" or "or." I don't know if that means you can only have a max of two items or a max of two item