Aw: Re: Validation problem

2025-05-12 Thread Ute Kaiser
Hi,

escaping does not matter.
Output for
error.maxlength=\'{0}\' can not be greater than {1} characters.
is the same as for 
error.maxlength='{0}' can not be greater than {1} characters.
(and the same as for error.maxlength={0} can not be greater than {1} 
characters.)
The '' always disappear.
I was looking for a solution because that worked in Struts1, and while 
migrating from Struts1 I wanted to keep the error messages the way my users are 
used to.

The links to the examples/mailreader2 do not use  with  but thx. They work different, and maybe a help to redesign my error 
messages.
Best regards
Ute


> Gesendet: Dienstag, 6. Mai 2025 um 10:55
> Von: "Lukasz Lenart" 
> An: "Struts Users Mailing List" 
> Betreff: Re: Validation problem
>

> 
> Not sure if I understood your issue, did you try to use escape char?
> 
> error.maxlength=\'{0}\' can not be greater than {1} characters.
> 
> > The example from the struts page is for requiredstring.
> > Is there an example for stringlength with maxlenght-output?
> 
> Take a look here
> https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/Registration-Registration_save-validation.xml#L9-L14
> 
> and error message definition
> https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/MailreaderSupport.properties#L94
> 
> there are also other examples, yet I'm not sure if they are up-to-date
> 
> > And where can I find all possible field-validator types?
> 
> Here is the list
> https://struts.apache.org/core-developers/validation#bundled-validators
> 
> 
> Cheers
> Łukasz
> 
> -
> 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: Validation problem

2025-05-06 Thread shankar sawate
Do you have a new implementation of the Dojo DateTimePicker? If so, please
share how to implement it, as the old one is deprecated

On Tue, 6 May, 2025, 2:27 pm Lukasz Lenart,  wrote:

> śr., 30 kwi 2025 o 19:47 Ute Kaiser  napisał(a):
> >
> > Hi,
> > I tried according to
> > https://struts.apache.org/core-developers/validation
> > Customizing validation messages
> > XML
> >
> > This is the example from above:
> > 
> > 
> > 
> > getText('username.field.name')
> > 
> > 
> > 
> > errors.required={0} is required.
> > username.field.name=Username
> > The final output will be as follow:
> > Username is required.
> >
> > Migrating from Struts1 to Struts7, this looked pretty familiar to me.
> > I tried
> >
> >   
> >  400
> >  
> > getText('myField.label')
> > ${maxLength}
> >  
> >   
> >
> > error.maxlength='{0}' can not be greater than {1} characters.
> > myField.label=myExample
> > Output:
> > {0} can not be greater than null characters.
> > When I use
> > error.maxlength={0} can not be greater than {1} characters. (without the
> '' which I want to use to emphasize the field name)
> > Output:
> > myExample can not be greater than null characters.
> >
> > I would like to have as output:
> > 'myExample' can not be greater than 400 characters.
>
> Not sure if I understood your issue, did you try to use escape char?
>
> error.maxlength=\'{0}\' can not be greater than {1} characters.
>
> > The example from the struts page is for requiredstring.
> > Is there an example for stringlength with maxlenght-output?
>
> Take a look here
>
> https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/Registration-Registration_save-validation.xml#L9-L14
>
> and error message definition
>
> https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/MailreaderSupport.properties#L94
>
> there are also other examples, yet I'm not sure if they are up-to-date
>
> > And where can I find all possible field-validator types?
>
> Here is the list
> https://struts.apache.org/core-developers/validation#bundled-validators
>
>
> Cheers
> Łukasz
>
> -
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


Re: Validation problem

2025-05-06 Thread Lukasz Lenart
śr., 30 kwi 2025 o 19:47 Ute Kaiser  napisał(a):
>
> Hi,
> I tried according to
> https://struts.apache.org/core-developers/validation
> Customizing validation messages
> XML
>
> This is the example from above:
> 
> 
> 
> getText('username.field.name')
> 
> 
> 
> errors.required={0} is required.
> username.field.name=Username
> The final output will be as follow:
> Username is required.
>
> Migrating from Struts1 to Struts7, this looked pretty familiar to me.
> I tried
>
>   
>  400
>  
> getText('myField.label')
> ${maxLength}
>  
>   
>
> error.maxlength='{0}' can not be greater than {1} characters.
> myField.label=myExample
> Output:
> {0} can not be greater than null characters.
> When I use
> error.maxlength={0} can not be greater than {1} characters. (without the '' 
> which I want to use to emphasize the field name)
> Output:
> myExample can not be greater than null characters.
>
> I would like to have as output:
> 'myExample' can not be greater than 400 characters.

Not sure if I understood your issue, did you try to use escape char?

error.maxlength=\'{0}\' can not be greater than {1} characters.

> The example from the struts page is for requiredstring.
> Is there an example for stringlength with maxlenght-output?

Take a look here
https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/Registration-Registration_save-validation.xml#L9-L14

and error message definition
https://github.com/apache/struts-examples/blob/main/mailreader2/src/main/resources/org/apache/struts/examples/mailreader2/MailreaderSupport.properties#L94

there are also other examples, yet I'm not sure if they are up-to-date

> And where can I find all possible field-validator types?

Here is the list
https://struts.apache.org/core-developers/validation#bundled-validators


Cheers
Łukasz

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-26 Thread Lukasz Lenart
2014-12-26 18:25 GMT+01:00 Yaragalla Muralidhar :
> Thank you Lukasz. I have rectified all the mistakes that u listed.
> Validations are working. I also have done some simple mistakes. I have
> rectified all the mistakes. Everything is working fine now. Thanks to all
> of you.

Great to hear that!


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-26 Thread Yaragalla Muralidhar
Thank you Lukasz. I have rectified all the mistakes that u listed.
Validations are working. I also have done some simple mistakes. I have
rectified all the mistakes. Everything is working fine now. Thanks to all
of you.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Fri, Dec 26, 2014 at 8:09 PM, Lukasz Lenart 
wrote:

> 2014-12-26 15:19 GMT+01:00 Lukasz Lenart :
> > 2014-12-26 6:56 GMT+01:00 Yaragalla Muralidhar <
> [email protected]>:
> >> Hi Sreekanth,
> >>   I think i cannot send attachements to the mailing list so i have
> >> uploaded the project to my drive and sharing the link
> >>
> >>
> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
>
> Can you start that app? I've noticed  file="mailreader-default.xml"/> in sample-reg.xml but such file
> doesn't exist which means Struts will blow up with some error in the
> logs.
>
> Another thing, even empty text field means something - an empty string
> - if you read the docs [1] it will clearly says:
> "RequiredFieldValidator checks if the specified field is not null."
> where empty string != null
>
> I think you want to specify min length of the String so you should use
> stringlength [2] instead. One more remark: you don't have to put
> validators.xml - it's only needed when you define your own validators.
> And I kindly suggest, please re-read the docs about how to setup
> validation and what each of the validators do [3].
>
> [1] http://struts.apache.org/docs/required-validator.html
> [2] http://struts.apache.org/docs/stringlength-validator.html
> [3] http://struts.apache.org/docs/validation.html
>
>
> Regards
> --
> Łukasz
> + 48 606 323 122 http://www.lenart.org.pl/
>
> -
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


Re: validation problem

2014-12-26 Thread Lukasz Lenart
2014-12-26 15:19 GMT+01:00 Lukasz Lenart :
> 2014-12-26 6:56 GMT+01:00 Yaragalla Muralidhar :
>> Hi Sreekanth,
>>   I think i cannot send attachements to the mailing list so i have
>> uploaded the project to my drive and sharing the link
>>
>> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing

Can you start that app? I've noticed  in sample-reg.xml but such file
doesn't exist which means Struts will blow up with some error in the
logs.

Another thing, even empty text field means something - an empty string
- if you read the docs [1] it will clearly says:
"RequiredFieldValidator checks if the specified field is not null."
where empty string != null

I think you want to specify min length of the String so you should use
stringlength [2] instead. One more remark: you don't have to put
validators.xml - it's only needed when you define your own validators.
And I kindly suggest, please re-read the docs about how to setup
validation and what each of the validators do [3].

[1] http://struts.apache.org/docs/required-validator.html
[2] http://struts.apache.org/docs/stringlength-validator.html
[3] http://struts.apache.org/docs/validation.html


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-26 Thread Lukasz Lenart
2014-12-26 15:19 GMT+01:00 Lukasz Lenart :
> 2014-12-26 6:56 GMT+01:00 Yaragalla Muralidhar :
>> Hi Sreekanth,
>>   I think i cannot send attachements to the mailing list so i have
>> uploaded the project to my drive and sharing the link
>>
>> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
>
> Can you pack all the files with zip or something like that and share
> the archive?

Nvm, got it :)


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-26 Thread Lukasz Lenart
2014-12-26 6:56 GMT+01:00 Yaragalla Muralidhar :
> Hi Sreekanth,
>   I think i cannot send attachements to the mailing list so i have
> uploaded the project to my drive and sharing the link
>
> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing

Can you pack all the files with zip or something like that and share
the archive?


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-26 Thread Yaragalla Muralidhar
I will do that. Thank you so much.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Fri, Dec 26, 2014 at 3:14 PM, Sreekanth S. Nair <
[email protected]> wrote:

> There is nothing about sorry, i guess your action package structure or
> something is wrong, i recommend you to run the sample war i have attached
> in tomcat 7 and see the result (make sure to include strust2 latest lib to
> its WEB-INF/lib). Try adding your action class one by one to that sample
> and try again.
>
>
>
>
> On Fri, Dec 26, 2014 at 3:07 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
> > Hi Sreekanth,
> >sorry to say this. I tried everything stated in the example that u
> gave.
> > but it did not work for me. I am doing something wrong but could not find
> > out what. Thank u for all your help.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Fri, Dec 26, 2014 at 12:24 PM, Sreekanth S. Nair <
> > [email protected]> wrote:
> >
> > > I couldn't make your sample war run at all, please find the attached
> > > sample war which is working for me in tomcat 7 (struts2 jars and other
> > dep
> > > not included). You can follow the directory structure and naming
> > convention
> > > and try to do the same in your project. Do not add @SkipValidation
> > > annotation in your save or submit method (@SkipValidation will in fact
> > > ignore validation for it)
> > >
> > > --
> > > Thanks & Regards
> > >
> > > Sreekanth S Nair
> > > Java Developer
> > > ---
> > > eGovernments Foundation 
> > > Ph : 9980078913
> > > ---
> > > 
> > >    
> > > 
> > > ---
> > >
> > > On Fri, Dec 26, 2014 at 11:32 AM, Sreekanth S. Nair <
> > > [email protected]> wrote:
> > >
> > >> Ok let me try and will get back to you...
> > >>
> > >>
> > >> On Fri, Dec 26, 2014 at 11:26 AM, Yaragalla Muralidhar <
> > >> [email protected]> wrote:
> > >>
> > >>> Hi Sreekanth,
> > >>>   I think i cannot send attachements to the mailing list so i
> have
> > >>> uploaded the project to my drive and sharing the link
> > >>>
> > >>>
> > >>>
> >
> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
> > >>>
> > >>>
> > >>> i am using tomcat 7.
> > >>>
> > >>> *Thanks and Regards,*
> > >>> Muralidhar Yaragalla.
> > >>>
> > >>> *http://yaragalla.blogspot.in/ *
> > >>>
> > >>> On Fri, Dec 26, 2014 at 9:32 AM, Sreekanth S. Nair <
> > >>> [email protected]> wrote:
> > >>>
> > >>> > Can you share a sample project which is not working, and just let
> me
> > >>> know
> > >>> > which server you are trying..?
> > >>> >
> > >>> > --
> > >>> > Thanks & Regards
> > >>> >
> > >>> > Sreekanth S Nair
> > >>> > Java Developer
> > >>> > ---
> > >>> > eGovernments Foundation 
> > >>> > Ph : 9980078913
> > >>> > ---
> > >>> > 
> > >>> >    <
> [email protected]>
> > >>> > 
> > >>> > ---
> > >>> >
> > >>> > On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
> > >>> > [email protected]> wrote:
> > >>> >
> > >>> > > Hi sreekanth,
> > >>> > >I have changed the names as u suggested but it did not
> > >>> work. i
> > >>> > > have read the link u posted and i did everything that the link
> > says.
> > >>> i
> > >>> > have
> > >>> > > debugged as well. it is not throwing any error.
> > >>> > >
> > >>> > > *Thanks and Regards,*
> > >>> > > Muralidhar Yaragalla.
> > >>> > >
> > >>> > > *http://yaragalla.blogspot.in/ *
> > >>> > >
> > >>> > > On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
> > >>> > > [email protected]> wrote:
> > >>> > >
> > >>> > > > As Dave said, kindly show some patience.
> > >>> > > >
> > >>> > > > First of validation is nothing to do with theme so just leave
> the
> > >>> theme
> > >>> > > > alone.
> > >>> > > >
> > >>> > > > 1) Can you try renaming the action class name from SampleRegOne
> > to
> > >>> > > > SampleRegOneAction
> > >>> > > > and same in struts.xml
> > >>> > > >
> > >>> > > > 2) If you give action alias name like below,
> > >>> > > >   > >>> > > > class="com.zedlabs.samplereg.action.SampleRegOne" >
> > >>> > > >
> > >>> > > > as far as i understood you need to use the alias name suffixed
> > >>> along
> > >>> > with
> > >>> > > > the action class name so in essence your validator xml name
> > should
> > >>> be
> > >>> > > some
> >

Re: validation problem

2014-12-26 Thread Sreekanth S. Nair
There is nothing about sorry, i guess your action package structure or
something is wrong, i recommend you to run the sample war i have attached
in tomcat 7 and see the result (make sure to include strust2 latest lib to
its WEB-INF/lib). Try adding your action class one by one to that sample
and try again.




On Fri, Dec 26, 2014 at 3:07 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> Hi Sreekanth,
>sorry to say this. I tried everything stated in the example that u gave.
> but it did not work for me. I am doing something wrong but could not find
> out what. Thank u for all your help.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Fri, Dec 26, 2014 at 12:24 PM, Sreekanth S. Nair <
> [email protected]> wrote:
>
> > I couldn't make your sample war run at all, please find the attached
> > sample war which is working for me in tomcat 7 (struts2 jars and other
> dep
> > not included). You can follow the directory structure and naming
> convention
> > and try to do the same in your project. Do not add @SkipValidation
> > annotation in your save or submit method (@SkipValidation will in fact
> > ignore validation for it)
> >
> > --
> > Thanks & Regards
> >
> > Sreekanth S Nair
> > Java Developer
> > ---
> > eGovernments Foundation 
> > Ph : 9980078913
> > ---
> > 
> >    
> > 
> > ---
> >
> > On Fri, Dec 26, 2014 at 11:32 AM, Sreekanth S. Nair <
> > [email protected]> wrote:
> >
> >> Ok let me try and will get back to you...
> >>
> >>
> >> On Fri, Dec 26, 2014 at 11:26 AM, Yaragalla Muralidhar <
> >> [email protected]> wrote:
> >>
> >>> Hi Sreekanth,
> >>>   I think i cannot send attachements to the mailing list so i have
> >>> uploaded the project to my drive and sharing the link
> >>>
> >>>
> >>>
> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
> >>>
> >>>
> >>> i am using tomcat 7.
> >>>
> >>> *Thanks and Regards,*
> >>> Muralidhar Yaragalla.
> >>>
> >>> *http://yaragalla.blogspot.in/ *
> >>>
> >>> On Fri, Dec 26, 2014 at 9:32 AM, Sreekanth S. Nair <
> >>> [email protected]> wrote:
> >>>
> >>> > Can you share a sample project which is not working, and just let me
> >>> know
> >>> > which server you are trying..?
> >>> >
> >>> > --
> >>> > Thanks & Regards
> >>> >
> >>> > Sreekanth S Nair
> >>> > Java Developer
> >>> > ---
> >>> > eGovernments Foundation 
> >>> > Ph : 9980078913
> >>> > ---
> >>> > 
> >>> >    
> >>> > 
> >>> > ---
> >>> >
> >>> > On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
> >>> > [email protected]> wrote:
> >>> >
> >>> > > Hi sreekanth,
> >>> > >I have changed the names as u suggested but it did not
> >>> work. i
> >>> > > have read the link u posted and i did everything that the link
> says.
> >>> i
> >>> > have
> >>> > > debugged as well. it is not throwing any error.
> >>> > >
> >>> > > *Thanks and Regards,*
> >>> > > Muralidhar Yaragalla.
> >>> > >
> >>> > > *http://yaragalla.blogspot.in/ *
> >>> > >
> >>> > > On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
> >>> > > [email protected]> wrote:
> >>> > >
> >>> > > > As Dave said, kindly show some patience.
> >>> > > >
> >>> > > > First of validation is nothing to do with theme so just leave the
> >>> theme
> >>> > > > alone.
> >>> > > >
> >>> > > > 1) Can you try renaming the action class name from SampleRegOne
> to
> >>> > > > SampleRegOneAction
> >>> > > > and same in struts.xml
> >>> > > >
> >>> > > > 2) If you give action alias name like below,
> >>> > > >   >>> > > > class="com.zedlabs.samplereg.action.SampleRegOne" >
> >>> > > >
> >>> > > > as far as i understood you need to use the alias name suffixed
> >>> along
> >>> > with
> >>> > > > the action class name so in essence your validator xml name
> should
> >>> be
> >>> > > some
> >>> > > > thing like below
> >>> > > >
> >>> > > > SampleRegOne-sampleRegOne-validation.xml
> >>> > > >
> >>> > > > Since i don't have much knowledge in xml based validation i
> >>> recommend
> >>> > you
> >>> > > > to read upon struts2 xml based validation from the below link
> >>> > > >
> >>> > > >
> >>> > >
> >>> >
> >>>
> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
> >>> > > >
> >>> > > > If the above solution is not working then try and figure out the
> >>> > problem
> >>> > > by
> >>> > > > deb

Re: validation problem

2014-12-26 Thread Yaragalla Muralidhar
Hi Sreekanth,
   sorry to say this. I tried everything stated in the example that u gave.
but it did not work for me. I am doing something wrong but could not find
out what. Thank u for all your help.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Fri, Dec 26, 2014 at 12:24 PM, Sreekanth S. Nair <
[email protected]> wrote:

> I couldn't make your sample war run at all, please find the attached
> sample war which is working for me in tomcat 7 (struts2 jars and other dep
> not included). You can follow the directory structure and naming convention
> and try to do the same in your project. Do not add @SkipValidation
> annotation in your save or submit method (@SkipValidation will in fact
> ignore validation for it)
>
> --
> Thanks & Regards
>
> Sreekanth S Nair
> Java Developer
> ---
> eGovernments Foundation 
> Ph : 9980078913
> ---
> 
>    
> 
> ---
>
> On Fri, Dec 26, 2014 at 11:32 AM, Sreekanth S. Nair <
> [email protected]> wrote:
>
>> Ok let me try and will get back to you...
>>
>>
>> On Fri, Dec 26, 2014 at 11:26 AM, Yaragalla Muralidhar <
>> [email protected]> wrote:
>>
>>> Hi Sreekanth,
>>>   I think i cannot send attachements to the mailing list so i have
>>> uploaded the project to my drive and sharing the link
>>>
>>>
>>> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
>>>
>>>
>>> i am using tomcat 7.
>>>
>>> *Thanks and Regards,*
>>> Muralidhar Yaragalla.
>>>
>>> *http://yaragalla.blogspot.in/ *
>>>
>>> On Fri, Dec 26, 2014 at 9:32 AM, Sreekanth S. Nair <
>>> [email protected]> wrote:
>>>
>>> > Can you share a sample project which is not working, and just let me
>>> know
>>> > which server you are trying..?
>>> >
>>> > --
>>> > Thanks & Regards
>>> >
>>> > Sreekanth S Nair
>>> > Java Developer
>>> > ---
>>> > eGovernments Foundation 
>>> > Ph : 9980078913
>>> > ---
>>> > 
>>> >    
>>> > 
>>> > ---
>>> >
>>> > On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
>>> > [email protected]> wrote:
>>> >
>>> > > Hi sreekanth,
>>> > >I have changed the names as u suggested but it did not
>>> work. i
>>> > > have read the link u posted and i did everything that the link says.
>>> i
>>> > have
>>> > > debugged as well. it is not throwing any error.
>>> > >
>>> > > *Thanks and Regards,*
>>> > > Muralidhar Yaragalla.
>>> > >
>>> > > *http://yaragalla.blogspot.in/ *
>>> > >
>>> > > On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
>>> > > [email protected]> wrote:
>>> > >
>>> > > > As Dave said, kindly show some patience.
>>> > > >
>>> > > > First of validation is nothing to do with theme so just leave the
>>> theme
>>> > > > alone.
>>> > > >
>>> > > > 1) Can you try renaming the action class name from SampleRegOne to
>>> > > > SampleRegOneAction
>>> > > > and same in struts.xml
>>> > > >
>>> > > > 2) If you give action alias name like below,
>>> > > >  >> > > > class="com.zedlabs.samplereg.action.SampleRegOne" >
>>> > > >
>>> > > > as far as i understood you need to use the alias name suffixed
>>> along
>>> > with
>>> > > > the action class name so in essence your validator xml name should
>>> be
>>> > > some
>>> > > > thing like below
>>> > > >
>>> > > > SampleRegOne-sampleRegOne-validation.xml
>>> > > >
>>> > > > Since i don't have much knowledge in xml based validation i
>>> recommend
>>> > you
>>> > > > to read upon struts2 xml based validation from the below link
>>> > > >
>>> > > >
>>> > >
>>> >
>>> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
>>> > > >
>>> > > > If the above solution is not working then try and figure out the
>>> > problem
>>> > > by
>>> > > > debugging through struts2 source.
>>> > > >
>>> > > > If the above solutions couldn't resolve your problem then get some
>>> > debug
>>> > > > level log of struts2 while accessing that particular action and
>>> post it
>>> > > > over here.
>>> > > >
>>> > > >
>>> > > >
>>> > > >
>>> > > > On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton <
>>> [email protected]>
>>> > > > wrote:
>>> > > >
>>> > > > > Unrelated to the technical issue: bear in mind the mailing list
>>> is a
>>> > > > > volunteer-"staffed" resource. Nobody is deliberately delaying a
>>> > > > > response. We already know you need help. In the US, at least,
>>> it's a
>>> > > > > fairly major holiday, and people are do

Re: validation problem

2014-12-25 Thread Sreekanth S. Nair
Ok let me try and will get back to you...

On Fri, Dec 26, 2014 at 11:26 AM, Yaragalla Muralidhar <
[email protected]> wrote:

> Hi Sreekanth,
>   I think i cannot send attachements to the mailing list so i have
> uploaded the project to my drive and sharing the link
>
>
> https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing
>
>
> i am using tomcat 7.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Fri, Dec 26, 2014 at 9:32 AM, Sreekanth S. Nair <
> [email protected]> wrote:
>
> > Can you share a sample project which is not working, and just let me know
> > which server you are trying..?
> >
> > --
> > Thanks & Regards
> >
> > Sreekanth S Nair
> > Java Developer
> > ---
> > eGovernments Foundation 
> > Ph : 9980078913
> > ---
> > 
> >    
> > 
> > ---
> >
> > On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
> > [email protected]> wrote:
> >
> > > Hi sreekanth,
> > >I have changed the names as u suggested but it did not
> work. i
> > > have read the link u posted and i did everything that the link says. i
> > have
> > > debugged as well. it is not throwing any error.
> > >
> > > *Thanks and Regards,*
> > > Muralidhar Yaragalla.
> > >
> > > *http://yaragalla.blogspot.in/ *
> > >
> > > On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
> > > [email protected]> wrote:
> > >
> > > > As Dave said, kindly show some patience.
> > > >
> > > > First of validation is nothing to do with theme so just leave the
> theme
> > > > alone.
> > > >
> > > > 1) Can you try renaming the action class name from SampleRegOne to
> > > > SampleRegOneAction
> > > > and same in struts.xml
> > > >
> > > > 2) If you give action alias name like below,
> > > >   > > > class="com.zedlabs.samplereg.action.SampleRegOne" >
> > > >
> > > > as far as i understood you need to use the alias name suffixed along
> > with
> > > > the action class name so in essence your validator xml name should be
> > > some
> > > > thing like below
> > > >
> > > > SampleRegOne-sampleRegOne-validation.xml
> > > >
> > > > Since i don't have much knowledge in xml based validation i recommend
> > you
> > > > to read upon struts2 xml based validation from the below link
> > > >
> > > >
> > >
> >
> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
> > > >
> > > > If the above solution is not working then try and figure out the
> > problem
> > > by
> > > > debugging through struts2 source.
> > > >
> > > > If the above solutions couldn't resolve your problem then get some
> > debug
> > > > level log of struts2 while accessing that particular action and post
> it
> > > > over here.
> > > >
> > > >
> > > >
> > > >
> > > > On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton 
> > > > wrote:
> > > >
> > > > > Unrelated to the technical issue: bear in mind the mailing list is
> a
> > > > > volunteer-"staffed" resource. Nobody is deliberately delaying a
> > > > > response. We already know you need help. In the US, at least, it's
> a
> > > > > fairly major holiday, and people are doing things besides trying to
> > > > > reproduce your environment and code to help out.
> > > > >
> > > > > With that in mind, please be patient.
> > > > >
> > > > >
> > > > > On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
> > > > >  wrote:
> > > > > > kindly help me solve this issue
> > > > > >
> > > > > > *Thanks and Regards,*
> > > > > > Muralidhar Yaragalla.
> > > > > >
> > > > > > *http://yaragalla.blogspot.in/ *
> > > > > >
> > > > > > On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> > > > > > [email protected]> wrote:
> > > > > >
> > > > > >> my struts config.xml is as below.kindly help me in solving this.
> > > > > >>
> > > > > >> 
> > > > > >>  > > > > >> "-//Apache Software Foundation//DTD Struts Configuration
> 2.3//EN"
> > > > > >> "http://struts.apache.org/dtds/struts-2.3.dtd";>
> > > > > >>
> > > > > >> 
> > > > > >>
> > > > > >>  > > > > value="false" />
> > > > > >> 
> > > > > >>
> > > > > >>
> > > > > >>
> > > > > >> 
> > > > > >>
> > > > > >>  
> > > > > >> 
> > > > > >>   
> > > > > >> 
> > > > > >> 
> > > > > >>
> > > > > >> 
> > > > > >>
> > > > > >> 
> > > > > >> /error.jsp
> > > > > >> 
> > > > > >>
> > > > > >> 
> > > > > >>  > > > > >> result="error"/>
> > > > > >> 
> > > > > >>
> > > > > >>> > > > class="com.zedlabs.samplereg.action.InitialAction"
> > > > > >> >
> > > > > >>  > > > > >/sampleReg/jsp/sampleRegTemplate.jsp
> > > > > >>
> > > > > >> 

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
Hi Sreekanth,
  I think i cannot send attachements to the mailing list so i have
uploaded the project to my drive and sharing the link

https://drive.google.com/file/d/0B59LVhKQaKQYamZqbnc4NGtOQm8/view?usp=sharing


i am using tomcat 7.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Fri, Dec 26, 2014 at 9:32 AM, Sreekanth S. Nair <
[email protected]> wrote:

> Can you share a sample project which is not working, and just let me know
> which server you are trying..?
>
> --
> Thanks & Regards
>
> Sreekanth S Nair
> Java Developer
> ---
> eGovernments Foundation 
> Ph : 9980078913
> ---
> 
>    
> 
> ---
>
> On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
> > Hi sreekanth,
> >I have changed the names as u suggested but it did not work. i
> > have read the link u posted and i did everything that the link says. i
> have
> > debugged as well. it is not throwing any error.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
> > [email protected]> wrote:
> >
> > > As Dave said, kindly show some patience.
> > >
> > > First of validation is nothing to do with theme so just leave the theme
> > > alone.
> > >
> > > 1) Can you try renaming the action class name from SampleRegOne to
> > > SampleRegOneAction
> > > and same in struts.xml
> > >
> > > 2) If you give action alias name like below,
> > >   > > class="com.zedlabs.samplereg.action.SampleRegOne" >
> > >
> > > as far as i understood you need to use the alias name suffixed along
> with
> > > the action class name so in essence your validator xml name should be
> > some
> > > thing like below
> > >
> > > SampleRegOne-sampleRegOne-validation.xml
> > >
> > > Since i don't have much knowledge in xml based validation i recommend
> you
> > > to read upon struts2 xml based validation from the below link
> > >
> > >
> >
> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
> > >
> > > If the above solution is not working then try and figure out the
> problem
> > by
> > > debugging through struts2 source.
> > >
> > > If the above solutions couldn't resolve your problem then get some
> debug
> > > level log of struts2 while accessing that particular action and post it
> > > over here.
> > >
> > >
> > >
> > >
> > > On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton 
> > > wrote:
> > >
> > > > Unrelated to the technical issue: bear in mind the mailing list is a
> > > > volunteer-"staffed" resource. Nobody is deliberately delaying a
> > > > response. We already know you need help. In the US, at least, it's a
> > > > fairly major holiday, and people are doing things besides trying to
> > > > reproduce your environment and code to help out.
> > > >
> > > > With that in mind, please be patient.
> > > >
> > > >
> > > > On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
> > > >  wrote:
> > > > > kindly help me solve this issue
> > > > >
> > > > > *Thanks and Regards,*
> > > > > Muralidhar Yaragalla.
> > > > >
> > > > > *http://yaragalla.blogspot.in/ *
> > > > >
> > > > > On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> > > > > [email protected]> wrote:
> > > > >
> > > > >> my struts config.xml is as below.kindly help me in solving this.
> > > > >>
> > > > >> 
> > > > >>  > > > >> "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
> > > > >> "http://struts.apache.org/dtds/struts-2.3.dtd";>
> > > > >>
> > > > >> 
> > > > >>
> > > > >>  > > > value="false" />
> > > > >> 
> > > > >>
> > > > >>
> > > > >>
> > > > >> 
> > > > >>
> > > > >>  
> > > > >> 
> > > > >>   
> > > > >> 
> > > > >> 
> > > > >>
> > > > >> 
> > > > >>
> > > > >> 
> > > > >> /error.jsp
> > > > >> 
> > > > >>
> > > > >> 
> > > > >>  > > > >> result="error"/>
> > > > >> 
> > > > >>
> > > > >>> > > class="com.zedlabs.samplereg.action.InitialAction"
> > > > >> >
> > > > >>  > > > >/sampleReg/jsp/sampleRegTemplate.jsp
> > > > >>
> > > > >>   
> > > > >>
> > > > >>> > > >> class="com.zedlabs.samplereg.action.SampleRegOne" >
> > > > >>  > > > >> >/sampleReg/jsp/sampleRegTwoTemplate.jsp
> > > > >>  > > >/sampleReg/jsp/sampleRegTemplate.jsp
> > > > >>
> > > > >>   
> > > > >>> > > >> class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
> > > > >>  > > > >> >/sampleReg/jsp/sampleRegThreeTemplate.jsp
> > > > >>   
> > > > >>> > > >> class="com.zedlabs.samplereg.action.

Re: validation problem

2014-12-25 Thread Sreekanth S. Nair
Can you share a sample project which is not working, and just let me know
which server you are trying..?

-- 
Thanks & Regards

Sreekanth S Nair
Java Developer
---
eGovernments Foundation 
Ph : 9980078913
---

   

---

On Fri, Dec 26, 2014 at 9:10 AM, Yaragalla Muralidhar <
[email protected]> wrote:

> Hi sreekanth,
>I have changed the names as u suggested but it did not work. i
> have read the link u posted and i did everything that the link says. i have
> debugged as well. it is not throwing any error.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
> [email protected]> wrote:
>
> > As Dave said, kindly show some patience.
> >
> > First of validation is nothing to do with theme so just leave the theme
> > alone.
> >
> > 1) Can you try renaming the action class name from SampleRegOne to
> > SampleRegOneAction
> > and same in struts.xml
> >
> > 2) If you give action alias name like below,
> >   > class="com.zedlabs.samplereg.action.SampleRegOne" >
> >
> > as far as i understood you need to use the alias name suffixed along with
> > the action class name so in essence your validator xml name should be
> some
> > thing like below
> >
> > SampleRegOne-sampleRegOne-validation.xml
> >
> > Since i don't have much knowledge in xml based validation i recommend you
> > to read upon struts2 xml based validation from the below link
> >
> >
> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
> >
> > If the above solution is not working then try and figure out the problem
> by
> > debugging through struts2 source.
> >
> > If the above solutions couldn't resolve your problem then get some debug
> > level log of struts2 while accessing that particular action and post it
> > over here.
> >
> >
> >
> >
> > On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton 
> > wrote:
> >
> > > Unrelated to the technical issue: bear in mind the mailing list is a
> > > volunteer-"staffed" resource. Nobody is deliberately delaying a
> > > response. We already know you need help. In the US, at least, it's a
> > > fairly major holiday, and people are doing things besides trying to
> > > reproduce your environment and code to help out.
> > >
> > > With that in mind, please be patient.
> > >
> > >
> > > On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
> > >  wrote:
> > > > kindly help me solve this issue
> > > >
> > > > *Thanks and Regards,*
> > > > Muralidhar Yaragalla.
> > > >
> > > > *http://yaragalla.blogspot.in/ *
> > > >
> > > > On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> > > > [email protected]> wrote:
> > > >
> > > >> my struts config.xml is as below.kindly help me in solving this.
> > > >>
> > > >> 
> > > >>  > > >> "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
> > > >> "http://struts.apache.org/dtds/struts-2.3.dtd";>
> > > >>
> > > >> 
> > > >>
> > > >>  > > value="false" />
> > > >> 
> > > >>
> > > >>
> > > >>
> > > >> 
> > > >>
> > > >>  
> > > >> 
> > > >>   
> > > >> 
> > > >> 
> > > >>
> > > >> 
> > > >>
> > > >> 
> > > >> /error.jsp
> > > >> 
> > > >>
> > > >> 
> > > >>  > > >> result="error"/>
> > > >> 
> > > >>
> > > >>> > class="com.zedlabs.samplereg.action.InitialAction"
> > > >> >
> > > >>  > > >/sampleReg/jsp/sampleRegTemplate.jsp
> > > >>
> > > >>   
> > > >>
> > > >>> > >> class="com.zedlabs.samplereg.action.SampleRegOne" >
> > > >>  > > >> >/sampleReg/jsp/sampleRegTwoTemplate.jsp
> > > >>  > >/sampleReg/jsp/sampleRegTemplate.jsp
> > > >>
> > > >>   
> > > >>> > >> class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
> > > >>  > > >> >/sampleReg/jsp/sampleRegThreeTemplate.jsp
> > > >>   
> > > >>> > >> class="com.zedlabs.samplereg.action.SampleRegThreeAction" >
> > > >>  > > >> >/sampleReg/jsp/sampleRegFourTemplate.jsp
> > > >>   
> > > >>
> > > >> 
> > > >>
> > > >> 
> > > >>
> > > >> 
> > > >>
> > > >>
> > > >> *Thanks and Regards,*
> > > >> Muralidhar Yaragalla.
> > > >>
> > > >> *http://yaragalla.blogspot.in/ *
> > > >>
> > > >> On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
> > > >> [email protected]> wrote:
> > > >>
> > > >>> The following is my action class
> > > >>>
> > > >>> package com.zedlabs.samplereg.action;
> > > >>>
> > > >>> import java.util.HashMap;
> > > >>> import java.util.Map;
> > > >>>
> > > >>> import org.apache.commons.logging.Log;
> > > >>> import org.apache.commons.logging.LogFactory;
> > > >>>

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
Hi sreekanth,
   I have changed the names as u suggested but it did not work. i
have read the link u posted and i did everything that the link says. i have
debugged as well. it is not throwing any error.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 10:43 PM, Sreekanth S. Nair <
[email protected]> wrote:

> As Dave said, kindly show some patience.
>
> First of validation is nothing to do with theme so just leave the theme
> alone.
>
> 1) Can you try renaming the action class name from SampleRegOne to
> SampleRegOneAction
> and same in struts.xml
>
> 2) If you give action alias name like below,
>   class="com.zedlabs.samplereg.action.SampleRegOne" >
>
> as far as i understood you need to use the alias name suffixed along with
> the action class name so in essence your validator xml name should be some
> thing like below
>
> SampleRegOne-sampleRegOne-validation.xml
>
> Since i don't have much knowledge in xml based validation i recommend you
> to read upon struts2 xml based validation from the below link
>
> http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml
>
> If the above solution is not working then try and figure out the problem by
> debugging through struts2 source.
>
> If the above solutions couldn't resolve your problem then get some debug
> level log of struts2 while accessing that particular action and post it
> over here.
>
>
>
>
> On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton 
> wrote:
>
> > Unrelated to the technical issue: bear in mind the mailing list is a
> > volunteer-"staffed" resource. Nobody is deliberately delaying a
> > response. We already know you need help. In the US, at least, it's a
> > fairly major holiday, and people are doing things besides trying to
> > reproduce your environment and code to help out.
> >
> > With that in mind, please be patient.
> >
> >
> > On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
> >  wrote:
> > > kindly help me solve this issue
> > >
> > > *Thanks and Regards,*
> > > Muralidhar Yaragalla.
> > >
> > > *http://yaragalla.blogspot.in/ *
> > >
> > > On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> > > [email protected]> wrote:
> > >
> > >> my struts config.xml is as below.kindly help me in solving this.
> > >>
> > >> 
> > >>  > >> "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
> > >> "http://struts.apache.org/dtds/struts-2.3.dtd";>
> > >>
> > >> 
> > >>
> > >>  > value="false" />
> > >> 
> > >>
> > >>
> > >>
> > >> 
> > >>
> > >>  
> > >> 
> > >>   
> > >> 
> > >> 
> > >>
> > >> 
> > >>
> > >> 
> > >> /error.jsp
> > >> 
> > >>
> > >> 
> > >>  > >> result="error"/>
> > >> 
> > >>
> > >>> class="com.zedlabs.samplereg.action.InitialAction"
> > >> >
> > >>  > >/sampleReg/jsp/sampleRegTemplate.jsp
> > >>
> > >>   
> > >>
> > >>> >> class="com.zedlabs.samplereg.action.SampleRegOne" >
> > >>  > >> >/sampleReg/jsp/sampleRegTwoTemplate.jsp
> > >>  >/sampleReg/jsp/sampleRegTemplate.jsp
> > >>
> > >>   
> > >>> >> class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
> > >>  > >> >/sampleReg/jsp/sampleRegThreeTemplate.jsp
> > >>   
> > >>> >> class="com.zedlabs.samplereg.action.SampleRegThreeAction" >
> > >>  > >> >/sampleReg/jsp/sampleRegFourTemplate.jsp
> > >>   
> > >>
> > >> 
> > >>
> > >> 
> > >>
> > >> 
> > >>
> > >>
> > >> *Thanks and Regards,*
> > >> Muralidhar Yaragalla.
> > >>
> > >> *http://yaragalla.blogspot.in/ *
> > >>
> > >> On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
> > >> [email protected]> wrote:
> > >>
> > >>> The following is my action class
> > >>>
> > >>> package com.zedlabs.samplereg.action;
> > >>>
> > >>> import java.util.HashMap;
> > >>> import java.util.Map;
> > >>>
> > >>> import org.apache.commons.logging.Log;
> > >>> import org.apache.commons.logging.LogFactory;
> > >>>
> > >>> import com.zedlabs.action.ZedActionSupport;
> > >>> import com.zedlabs.samplereg.dto.PDDto;
> > >>> import com.zedlabs.samplereg.service.SampleRegService;
> > >>> import com.zedlabs.samplereg.service.SampleRegServiceImpl;
> > >>>
> > >>> public class SampleRegOne extends ZedActionSupport {
> > >>>
> > >>> private static final long serialVersionUID = -8621676046564513353L;
> > >>> private Log log=LogFactory.getLog(SampleRegOne.class);
> > >>> private SampleRegService sampleReg=new SampleRegServiceImpl();
> > >>>  private Map sampledrawnBy=new
> HashMap();
> > >>> private PDDto primaryDetails=new PDDto();
> > >>>  @Override
> > >>> public String execute() {
> > >>> try{
> > >>> sampledrawnBy.put("zedlabs", "Zedlabs");
> > >>> sampleReg.savePrimaryDetails(primaryDetails);
> > >>>  }catch(Exception e){
> > >>> log.error(e.getMessage(), e);
> > >>> }

Re: validation problem

2014-12-25 Thread Sreekanth S. Nair
As Dave said, kindly show some patience.

First of validation is nothing to do with theme so just leave the theme
alone.

1) Can you try renaming the action class name from SampleRegOne to
SampleRegOneAction
and same in struts.xml

2) If you give action alias name like below,
 

as far as i understood you need to use the alias name suffixed along with
the action class name so in essence your validator xml name should be some
thing like below

SampleRegOne-sampleRegOne-validation.xml

Since i don't have much knowledge in xml based validation i recommend you
to read upon struts2 xml based validation from the below link
http://www.codejava.net/frameworks/struts/struts2-form-validation-basic-example-using-xml

If the above solution is not working then try and figure out the problem by
debugging through struts2 source.

If the above solutions couldn't resolve your problem then get some debug
level log of struts2 while accessing that particular action and post it
over here.




On Thu, Dec 25, 2014 at 8:34 PM, Dave Newton  wrote:

> Unrelated to the technical issue: bear in mind the mailing list is a
> volunteer-"staffed" resource. Nobody is deliberately delaying a
> response. We already know you need help. In the US, at least, it's a
> fairly major holiday, and people are doing things besides trying to
> reproduce your environment and code to help out.
>
> With that in mind, please be patient.
>
>
> On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
>  wrote:
> > kindly help me solve this issue
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> > [email protected]> wrote:
> >
> >> my struts config.xml is as below.kindly help me in solving this.
> >>
> >> 
> >>  >> "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
> >> "http://struts.apache.org/dtds/struts-2.3.dtd";>
> >>
> >> 
> >>
> >>  value="false" />
> >> 
> >>
> >>
> >>
> >> 
> >>
> >>  
> >> 
> >>   
> >> 
> >> 
> >>
> >> 
> >>
> >> 
> >> /error.jsp
> >> 
> >>
> >> 
> >>  >> result="error"/>
> >> 
> >>
> >>class="com.zedlabs.samplereg.action.InitialAction"
> >> >
> >>  >/sampleReg/jsp/sampleRegTemplate.jsp
> >>
> >>   
> >>
> >>>> class="com.zedlabs.samplereg.action.SampleRegOne" >
> >>  >> >/sampleReg/jsp/sampleRegTwoTemplate.jsp
> >> /sampleReg/jsp/sampleRegTemplate.jsp
> >>
> >>   
> >>>> class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
> >>  >> >/sampleReg/jsp/sampleRegThreeTemplate.jsp
> >>   
> >>>> class="com.zedlabs.samplereg.action.SampleRegThreeAction" >
> >>  >> >/sampleReg/jsp/sampleRegFourTemplate.jsp
> >>   
> >>
> >> 
> >>
> >> 
> >>
> >> 
> >>
> >>
> >> *Thanks and Regards,*
> >> Muralidhar Yaragalla.
> >>
> >> *http://yaragalla.blogspot.in/ *
> >>
> >> On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
> >> [email protected]> wrote:
> >>
> >>> The following is my action class
> >>>
> >>> package com.zedlabs.samplereg.action;
> >>>
> >>> import java.util.HashMap;
> >>> import java.util.Map;
> >>>
> >>> import org.apache.commons.logging.Log;
> >>> import org.apache.commons.logging.LogFactory;
> >>>
> >>> import com.zedlabs.action.ZedActionSupport;
> >>> import com.zedlabs.samplereg.dto.PDDto;
> >>> import com.zedlabs.samplereg.service.SampleRegService;
> >>> import com.zedlabs.samplereg.service.SampleRegServiceImpl;
> >>>
> >>> public class SampleRegOne extends ZedActionSupport {
> >>>
> >>> private static final long serialVersionUID = -8621676046564513353L;
> >>> private Log log=LogFactory.getLog(SampleRegOne.class);
> >>> private SampleRegService sampleReg=new SampleRegServiceImpl();
> >>>  private Map sampledrawnBy=new HashMap();
> >>> private PDDto primaryDetails=new PDDto();
> >>>  @Override
> >>> public String execute() {
> >>> try{
> >>> sampledrawnBy.put("zedlabs", "Zedlabs");
> >>> sampleReg.savePrimaryDetails(primaryDetails);
> >>>  }catch(Exception e){
> >>> log.error(e.getMessage(), e);
> >>> }
> >>> return SUCCESS;
> >>> }
> >>>
> >>> public Map getSampledrawnBy() {
> >>> return sampledrawnBy;
> >>> }
> >>>
> >>> public void setSampledrawnBy(Map sampledrawnBy) {
> >>> this.sampledrawnBy = sampledrawnBy;
> >>> }
> >>>
> >>> public PDDto getPrimaryDetails() {
> >>> return primaryDetails;
> >>> }
> >>>
> >>> public void setPrimaryDetails(PDDto primaryDetails) {
> >>> this.primaryDetails = primaryDetails;
> >>> }
> >>>
> >>>
> >>> }
> >>>
> >>>
> >>> *Thanks and Regards,*
> >>> Muralidhar Yaragalla.
> >>>
> >>> *http://yaragalla.blogspot.in/ *
> >>>
> >>> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
> >>> [email protected]> wrote:
> >>>
>  if the validation works then i can think about messages
> 
>  *Thank

Re: validation problem

2014-12-25 Thread Dave Newton
Unrelated to the technical issue: bear in mind the mailing list is a
volunteer-"staffed" resource. Nobody is deliberately delaying a
response. We already know you need help. In the US, at least, it's a
fairly major holiday, and people are doing things besides trying to
reproduce your environment and code to help out.

With that in mind, please be patient.


On Thu, Dec 25, 2014 at 9:01 AM, Yaragalla Muralidhar
 wrote:
> kindly help me solve this issue
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
>> my struts config.xml is as below.kindly help me in solving this.
>>
>> 
>> > "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
>> "http://struts.apache.org/dtds/struts-2.3.dtd";>
>>
>> 
>>
>> 
>> 
>>
>>
>>
>> 
>>
>>  
>> 
>>   
>> 
>> 
>>
>> 
>>
>> 
>> /error.jsp
>> 
>>
>> 
>> > result="error"/>
>> 
>>
>>   > >
>> /sampleReg/jsp/sampleRegTemplate.jsp
>>
>>   
>>
>>   > class="com.zedlabs.samplereg.action.SampleRegOne" >
>> > >/sampleReg/jsp/sampleRegTwoTemplate.jsp
>> /sampleReg/jsp/sampleRegTemplate.jsp
>>
>>   
>>   > class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
>> > >/sampleReg/jsp/sampleRegThreeTemplate.jsp
>>   
>>   > class="com.zedlabs.samplereg.action.SampleRegThreeAction" >
>> > >/sampleReg/jsp/sampleRegFourTemplate.jsp
>>   
>>
>> 
>>
>> 
>>
>> 
>>
>>
>> *Thanks and Regards,*
>> Muralidhar Yaragalla.
>>
>> *http://yaragalla.blogspot.in/ *
>>
>> On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
>> [email protected]> wrote:
>>
>>> The following is my action class
>>>
>>> package com.zedlabs.samplereg.action;
>>>
>>> import java.util.HashMap;
>>> import java.util.Map;
>>>
>>> import org.apache.commons.logging.Log;
>>> import org.apache.commons.logging.LogFactory;
>>>
>>> import com.zedlabs.action.ZedActionSupport;
>>> import com.zedlabs.samplereg.dto.PDDto;
>>> import com.zedlabs.samplereg.service.SampleRegService;
>>> import com.zedlabs.samplereg.service.SampleRegServiceImpl;
>>>
>>> public class SampleRegOne extends ZedActionSupport {
>>>
>>> private static final long serialVersionUID = -8621676046564513353L;
>>> private Log log=LogFactory.getLog(SampleRegOne.class);
>>> private SampleRegService sampleReg=new SampleRegServiceImpl();
>>>  private Map sampledrawnBy=new HashMap();
>>> private PDDto primaryDetails=new PDDto();
>>>  @Override
>>> public String execute() {
>>> try{
>>> sampledrawnBy.put("zedlabs", "Zedlabs");
>>> sampleReg.savePrimaryDetails(primaryDetails);
>>>  }catch(Exception e){
>>> log.error(e.getMessage(), e);
>>> }
>>> return SUCCESS;
>>> }
>>>
>>> public Map getSampledrawnBy() {
>>> return sampledrawnBy;
>>> }
>>>
>>> public void setSampledrawnBy(Map sampledrawnBy) {
>>> this.sampledrawnBy = sampledrawnBy;
>>> }
>>>
>>> public PDDto getPrimaryDetails() {
>>> return primaryDetails;
>>> }
>>>
>>> public void setPrimaryDetails(PDDto primaryDetails) {
>>> this.primaryDetails = primaryDetails;
>>> }
>>>
>>>
>>> }
>>>
>>>
>>> *Thanks and Regards,*
>>> Muralidhar Yaragalla.
>>>
>>> *http://yaragalla.blogspot.in/ *
>>>
>>> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
>>> [email protected]> wrote:
>>>
 if the validation works then i can think about messages

 *Thanks and Regards,*
 Muralidhar Yaragalla.

 *http://yaragalla.blogspot.in/ *

 On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
 [email protected]> wrote:

> I have changed the theme to css_xhtml   so it should display right?
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton 
> wrote:
>
>> Then you're doing something else wrong; never mind.
>>
>> You still won't see the messages unless you display them manually.
>>
>> On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
>>  wrote:
>> > in my case validations are not happenening . Even though validation
>> fails
>> > it is moving to succeess rather than input jsp.
>> >
>> > *Thanks and Regards,*
>> > Muralidhar Yaragalla.
>> >
>> > *http://yaragalla.blogspot.in/ *
>> >
>> > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
>> wrote:
>> >
>> >> Please read up on the themes.
>> >>
>> >> Nutshell: validation happens (this is trivially provable),
>> validation
>> >> message display does not.
>> >>
>> >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
>> >>  wrote:
>> >> > is it because of the 

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
kindly help me solve this issue

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 8:02 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> my struts config.xml is as below.kindly help me in solving this.
>
> 
>  "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN"
> "http://struts.apache.org/dtds/struts-2.3.dtd";>
>
> 
>
> 
> 
>
>
>
> 
>
>  
> 
>   
> 
> 
>
> 
>
> 
> /error.jsp
> 
>
> 
>  result="error"/>
> 
>
>>
> /sampleReg/jsp/sampleRegTemplate.jsp
>
>   
>
>class="com.zedlabs.samplereg.action.SampleRegOne" >
>  >/sampleReg/jsp/sampleRegTwoTemplate.jsp
> /sampleReg/jsp/sampleRegTemplate.jsp
>
>   
>class="com.zedlabs.samplereg.action.SampleRegTwoAction" >
>  >/sampleReg/jsp/sampleRegThreeTemplate.jsp
>   
>class="com.zedlabs.samplereg.action.SampleRegThreeAction" >
>  >/sampleReg/jsp/sampleRegFourTemplate.jsp
>   
>
> 
>
> 
>
> 
>
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
>> The following is my action class
>>
>> package com.zedlabs.samplereg.action;
>>
>> import java.util.HashMap;
>> import java.util.Map;
>>
>> import org.apache.commons.logging.Log;
>> import org.apache.commons.logging.LogFactory;
>>
>> import com.zedlabs.action.ZedActionSupport;
>> import com.zedlabs.samplereg.dto.PDDto;
>> import com.zedlabs.samplereg.service.SampleRegService;
>> import com.zedlabs.samplereg.service.SampleRegServiceImpl;
>>
>> public class SampleRegOne extends ZedActionSupport {
>>
>> private static final long serialVersionUID = -8621676046564513353L;
>> private Log log=LogFactory.getLog(SampleRegOne.class);
>> private SampleRegService sampleReg=new SampleRegServiceImpl();
>>  private Map sampledrawnBy=new HashMap();
>> private PDDto primaryDetails=new PDDto();
>>  @Override
>> public String execute() {
>> try{
>> sampledrawnBy.put("zedlabs", "Zedlabs");
>> sampleReg.savePrimaryDetails(primaryDetails);
>>  }catch(Exception e){
>> log.error(e.getMessage(), e);
>> }
>> return SUCCESS;
>> }
>>
>> public Map getSampledrawnBy() {
>> return sampledrawnBy;
>> }
>>
>> public void setSampledrawnBy(Map sampledrawnBy) {
>> this.sampledrawnBy = sampledrawnBy;
>> }
>>
>> public PDDto getPrimaryDetails() {
>> return primaryDetails;
>> }
>>
>> public void setPrimaryDetails(PDDto primaryDetails) {
>> this.primaryDetails = primaryDetails;
>> }
>>
>>
>> }
>>
>>
>> *Thanks and Regards,*
>> Muralidhar Yaragalla.
>>
>> *http://yaragalla.blogspot.in/ *
>>
>> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
>> [email protected]> wrote:
>>
>>> if the validation works then i can think about messages
>>>
>>> *Thanks and Regards,*
>>> Muralidhar Yaragalla.
>>>
>>> *http://yaragalla.blogspot.in/ *
>>>
>>> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
>>> [email protected]> wrote:
>>>
 I have changed the theme to css_xhtml   so it should display right?

 *Thanks and Regards,*
 Muralidhar Yaragalla.

 *http://yaragalla.blogspot.in/ *

 On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton 
 wrote:

> Then you're doing something else wrong; never mind.
>
> You still won't see the messages unless you display them manually.
>
> On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
>  wrote:
> > in my case validations are not happenening . Even though validation
> fails
> > it is moving to succeess rather than input jsp.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
> wrote:
> >
> >> Please read up on the themes.
> >>
> >> Nutshell: validation happens (this is trivially provable),
> validation
> >> message display does not.
> >>
> >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
> >>  wrote:
> >> > is it because of the simple theam? In simple theam validations
> dont
> >> happen
> >> > is it? if i dont use simple theme view components are generating
> their
> >> own
> >> > decoration. Our custom alignment is going wrong.
> >> >
> >> > *Thanks and Regards,*
> >> > Muralidhar Yaragalla.
> >> >
> >> > *http://yaragalla.blogspot.in/ *
> >> >
> >> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton <
> [email protected]>
> >> wrote:
> >> >
> >> >> Simple theme is simpler than you think.
> >> >> On Dec 25, 2014 4:46 AM, "Yaragalla 

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
my struts config.xml is as below.kindly help me in solving this.


http://struts.apache.org/dtds/struts-2.3.dtd";>










 

  






/error.jsp






  
/sampleReg/jsp/sampleRegTemplate.jsp

  

  
/sampleReg/jsp/sampleRegTwoTemplate.jsp
/sampleReg/jsp/sampleRegTemplate.jsp
  
  
/sampleReg/jsp/sampleRegThreeTemplate.jsp
  
  
/sampleReg/jsp/sampleRegFourTemplate.jsp
  








*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 7:47 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> The following is my action class
>
> package com.zedlabs.samplereg.action;
>
> import java.util.HashMap;
> import java.util.Map;
>
> import org.apache.commons.logging.Log;
> import org.apache.commons.logging.LogFactory;
>
> import com.zedlabs.action.ZedActionSupport;
> import com.zedlabs.samplereg.dto.PDDto;
> import com.zedlabs.samplereg.service.SampleRegService;
> import com.zedlabs.samplereg.service.SampleRegServiceImpl;
>
> public class SampleRegOne extends ZedActionSupport {
>
> private static final long serialVersionUID = -8621676046564513353L;
> private Log log=LogFactory.getLog(SampleRegOne.class);
> private SampleRegService sampleReg=new SampleRegServiceImpl();
>  private Map sampledrawnBy=new HashMap();
> private PDDto primaryDetails=new PDDto();
>  @Override
> public String execute() {
> try{
> sampledrawnBy.put("zedlabs", "Zedlabs");
> sampleReg.savePrimaryDetails(primaryDetails);
>  }catch(Exception e){
> log.error(e.getMessage(), e);
> }
> return SUCCESS;
> }
>
> public Map getSampledrawnBy() {
> return sampledrawnBy;
> }
>
> public void setSampledrawnBy(Map sampledrawnBy) {
> this.sampledrawnBy = sampledrawnBy;
> }
>
> public PDDto getPrimaryDetails() {
> return primaryDetails;
> }
>
> public void setPrimaryDetails(PDDto primaryDetails) {
> this.primaryDetails = primaryDetails;
> }
>
>
> }
>
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
>> if the validation works then i can think about messages
>>
>> *Thanks and Regards,*
>> Muralidhar Yaragalla.
>>
>> *http://yaragalla.blogspot.in/ *
>>
>> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
>> [email protected]> wrote:
>>
>>> I have changed the theme to css_xhtml   so it should display right?
>>>
>>> *Thanks and Regards,*
>>> Muralidhar Yaragalla.
>>>
>>> *http://yaragalla.blogspot.in/ *
>>>
>>> On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton 
>>> wrote:
>>>
 Then you're doing something else wrong; never mind.

 You still won't see the messages unless you display them manually.

 On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
  wrote:
 > in my case validations are not happenening . Even though validation
 fails
 > it is moving to succeess rather than input jsp.
 >
 > *Thanks and Regards,*
 > Muralidhar Yaragalla.
 >
 > *http://yaragalla.blogspot.in/ *
 >
 > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
 wrote:
 >
 >> Please read up on the themes.
 >>
 >> Nutshell: validation happens (this is trivially provable), validation
 >> message display does not.
 >>
 >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
 >>  wrote:
 >> > is it because of the simple theam? In simple theam validations dont
 >> happen
 >> > is it? if i dont use simple theme view components are generating
 their
 >> own
 >> > decoration. Our custom alignment is going wrong.
 >> >
 >> > *Thanks and Regards,*
 >> > Muralidhar Yaragalla.
 >> >
 >> > *http://yaragalla.blogspot.in/ *
 >> >
 >> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton <
 [email protected]>
 >> wrote:
 >> >
 >> >> Simple theme is simpler than you think.
 >> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
 >> [email protected]
 >> >> >
 >> >> wrote:
 >> >>
 >> >> > I am using struts2.3.20 and using simple theme.
 >> >> >
 >> >> > *Thanks and Regards,*
 >> >> > Muralidhar Yaragalla.
 >> >> >
 >> >> > *http://yaragalla.blogspot.in/ *
 >> >> >
 >> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
 >> >> > [email protected]> wrote:
 >> >> >
 >> >> > > Hi i am having problem in turning on validations. I have
 written
 >> >> > > "actionClass-validation.xml" file in the same package as
 action
 >> class.
 >> >> > but
 >> >> > > the validations are not working. the following is my
>>>

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
The following is my action class

package com.zedlabs.samplereg.action;

import java.util.HashMap;
import java.util.Map;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.zedlabs.action.ZedActionSupport;
import com.zedlabs.samplereg.dto.PDDto;
import com.zedlabs.samplereg.service.SampleRegService;
import com.zedlabs.samplereg.service.SampleRegServiceImpl;

public class SampleRegOne extends ZedActionSupport {

private static final long serialVersionUID = -8621676046564513353L;
private Log log=LogFactory.getLog(SampleRegOne.class);
private SampleRegService sampleReg=new SampleRegServiceImpl();
 private Map sampledrawnBy=new HashMap();
private PDDto primaryDetails=new PDDto();
 @Override
public String execute() {
try{
sampledrawnBy.put("zedlabs", "Zedlabs");
sampleReg.savePrimaryDetails(primaryDetails);
 }catch(Exception e){
log.error(e.getMessage(), e);
}
return SUCCESS;
}

public Map getSampledrawnBy() {
return sampledrawnBy;
}

public void setSampledrawnBy(Map sampledrawnBy) {
this.sampledrawnBy = sampledrawnBy;
}

public PDDto getPrimaryDetails() {
return primaryDetails;
}

public void setPrimaryDetails(PDDto primaryDetails) {
this.primaryDetails = primaryDetails;
}


}


*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> if the validation works then i can think about messages
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
>> I have changed the theme to css_xhtml   so it should display right?
>>
>> *Thanks and Regards,*
>> Muralidhar Yaragalla.
>>
>> *http://yaragalla.blogspot.in/ *
>>
>> On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton 
>> wrote:
>>
>>> Then you're doing something else wrong; never mind.
>>>
>>> You still won't see the messages unless you display them manually.
>>>
>>> On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
>>>  wrote:
>>> > in my case validations are not happenening . Even though validation
>>> fails
>>> > it is moving to succeess rather than input jsp.
>>> >
>>> > *Thanks and Regards,*
>>> > Muralidhar Yaragalla.
>>> >
>>> > *http://yaragalla.blogspot.in/ *
>>> >
>>> > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
>>> wrote:
>>> >
>>> >> Please read up on the themes.
>>> >>
>>> >> Nutshell: validation happens (this is trivially provable), validation
>>> >> message display does not.
>>> >>
>>> >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
>>> >>  wrote:
>>> >> > is it because of the simple theam? In simple theam validations dont
>>> >> happen
>>> >> > is it? if i dont use simple theme view components are generating
>>> their
>>> >> own
>>> >> > decoration. Our custom alignment is going wrong.
>>> >> >
>>> >> > *Thanks and Regards,*
>>> >> > Muralidhar Yaragalla.
>>> >> >
>>> >> > *http://yaragalla.blogspot.in/ *
>>> >> >
>>> >> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton >> >
>>> >> wrote:
>>> >> >
>>> >> >> Simple theme is simpler than you think.
>>> >> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
>>> >> [email protected]
>>> >> >> >
>>> >> >> wrote:
>>> >> >>
>>> >> >> > I am using struts2.3.20 and using simple theme.
>>> >> >> >
>>> >> >> > *Thanks and Regards,*
>>> >> >> > Muralidhar Yaragalla.
>>> >> >> >
>>> >> >> > *http://yaragalla.blogspot.in/ *
>>> >> >> >
>>> >> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
>>> >> >> > [email protected]> wrote:
>>> >> >> >
>>> >> >> > > Hi i am having problem in turning on validations. I have
>>> written
>>> >> >> > > "actionClass-validation.xml" file in the same package as action
>>> >> class.
>>> >> >> > but
>>> >> >> > > the validations are not working. the following is my
>>> validation xml
>>> >> >> file.
>>> >> >> > >
>>> >> >> > > >> >> >> 1.0.3//EN"
>>> >> >> > > "
>>> http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
>>> >> >> > > 
>>> >> >> > >
>>> >> >> > > 
>>> >> >> > >  
>>> >> >> > >Could
>>> >> not
>>> >> >> > find
>>> >> >> > > error.additional.details.passport.no!
>>> >> >> > >  
>>> >> >> > >  
>>> >> >> > >   
>>> >> >> > >Could
>>> not
>>> >> >> find
>>> >> >> > > error.additional.details.pancard.no
>>> >> >> > >  
>>> >> >> > > 
>>> >> >> > >  
>>> >> >> > >  
>>> >> >> > >Could
>>> >> not
>>> >> >> > find
>>> >> >> > > error.additional.details.passport.no!
>>> >> >> > >  
>>> >> >> > >
>>> >> >> > > 
>>> >> >> > >
>>> >> >> > > 
>>> >> >> > >
>>> >> >> > > do i have to do something else to turn on validations?
>>> >> >> > >
>>> >> >> > >
>>> >> >> > > *Thanks and Regards,*
>>> >> >> > > Muralidhar Yara

Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
I have changed the theme to css_xhtml   so it should display right?

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton  wrote:

> Then you're doing something else wrong; never mind.
>
> You still won't see the messages unless you display them manually.
>
> On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
>  wrote:
> > in my case validations are not happenening . Even though validation fails
> > it is moving to succeess rather than input jsp.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
> wrote:
> >
> >> Please read up on the themes.
> >>
> >> Nutshell: validation happens (this is trivially provable), validation
> >> message display does not.
> >>
> >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
> >>  wrote:
> >> > is it because of the simple theam? In simple theam validations dont
> >> happen
> >> > is it? if i dont use simple theme view components are generating their
> >> own
> >> > decoration. Our custom alignment is going wrong.
> >> >
> >> > *Thanks and Regards,*
> >> > Muralidhar Yaragalla.
> >> >
> >> > *http://yaragalla.blogspot.in/ *
> >> >
> >> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton 
> >> wrote:
> >> >
> >> >> Simple theme is simpler than you think.
> >> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
> >> [email protected]
> >> >> >
> >> >> wrote:
> >> >>
> >> >> > I am using struts2.3.20 and using simple theme.
> >> >> >
> >> >> > *Thanks and Regards,*
> >> >> > Muralidhar Yaragalla.
> >> >> >
> >> >> > *http://yaragalla.blogspot.in/ *
> >> >> >
> >> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
> >> >> > [email protected]> wrote:
> >> >> >
> >> >> > > Hi i am having problem in turning on validations. I have written
> >> >> > > "actionClass-validation.xml" file in the same package as action
> >> class.
> >> >> > but
> >> >> > > the validations are not working. the following is my validation
> xml
> >> >> file.
> >> >> > >
> >> >> > >  >> >> 1.0.3//EN"
> >> >> > > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd
> ">
> >> >> > > 
> >> >> > >
> >> >> > > 
> >> >> > >  
> >> >> > >Could
> >> not
> >> >> > find
> >> >> > > error.additional.details.passport.no!
> >> >> > >  
> >> >> > >  
> >> >> > >   
> >> >> > >Could
> not
> >> >> find
> >> >> > > error.additional.details.pancard.no
> >> >> > >  
> >> >> > > 
> >> >> > >  
> >> >> > >  
> >> >> > >Could
> >> not
> >> >> > find
> >> >> > > error.additional.details.passport.no!
> >> >> > >  
> >> >> > >
> >> >> > > 
> >> >> > >
> >> >> > > 
> >> >> > >
> >> >> > > do i have to do something else to turn on validations?
> >> >> > >
> >> >> > >
> >> >> > > *Thanks and Regards,*
> >> >> > > Muralidhar Yaragalla.
> >> >> > >
> >> >> > > *http://yaragalla.blogspot.in/ *
> >> >> > >
> >> >> >
> >> >>
> >>
> >>
> >>
> >> --
> >> e: [email protected]
> >> m: 908-380-8699
> >> s: davelnewton_skype
> >> t: @dave_newton
> >> b: Bucky Bits
> >> g: davelnewton
> >> so: Dave Newton
> >>
> >> -
> >> To unsubscribe, e-mail: [email protected]
> >> For additional commands, e-mail: [email protected]
> >>
> >>
>
>
>
> --
> e: [email protected]
> m: 908-380-8699
> s: davelnewton_skype
> t: @dave_newton
> b: Bucky Bits
> g: davelnewton
> so: Dave Newton
>
> -
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
if the validation works then i can think about messages

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 6:30 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> I have changed the theme to css_xhtml   so it should display right?
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 6:28 PM, Dave Newton 
> wrote:
>
>> Then you're doing something else wrong; never mind.
>>
>> You still won't see the messages unless you display them manually.
>>
>> On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
>>  wrote:
>> > in my case validations are not happenening . Even though validation
>> fails
>> > it is moving to succeess rather than input jsp.
>> >
>> > *Thanks and Regards,*
>> > Muralidhar Yaragalla.
>> >
>> > *http://yaragalla.blogspot.in/ *
>> >
>> > On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton 
>> wrote:
>> >
>> >> Please read up on the themes.
>> >>
>> >> Nutshell: validation happens (this is trivially provable), validation
>> >> message display does not.
>> >>
>> >> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
>> >>  wrote:
>> >> > is it because of the simple theam? In simple theam validations dont
>> >> happen
>> >> > is it? if i dont use simple theme view components are generating
>> their
>> >> own
>> >> > decoration. Our custom alignment is going wrong.
>> >> >
>> >> > *Thanks and Regards,*
>> >> > Muralidhar Yaragalla.
>> >> >
>> >> > *http://yaragalla.blogspot.in/ *
>> >> >
>> >> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton 
>> >> wrote:
>> >> >
>> >> >> Simple theme is simpler than you think.
>> >> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
>> >> [email protected]
>> >> >> >
>> >> >> wrote:
>> >> >>
>> >> >> > I am using struts2.3.20 and using simple theme.
>> >> >> >
>> >> >> > *Thanks and Regards,*
>> >> >> > Muralidhar Yaragalla.
>> >> >> >
>> >> >> > *http://yaragalla.blogspot.in/ *
>> >> >> >
>> >> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
>> >> >> > [email protected]> wrote:
>> >> >> >
>> >> >> > > Hi i am having problem in turning on validations. I have written
>> >> >> > > "actionClass-validation.xml" file in the same package as action
>> >> class.
>> >> >> > but
>> >> >> > > the validations are not working. the following is my validation
>> xml
>> >> >> file.
>> >> >> > >
>> >> >> > > > >> >> 1.0.3//EN"
>> >> >> > > "
>> http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
>> >> >> > > 
>> >> >> > >
>> >> >> > > 
>> >> >> > >  
>> >> >> > >Could
>> >> not
>> >> >> > find
>> >> >> > > error.additional.details.passport.no!
>> >> >> > >  
>> >> >> > >  
>> >> >> > >   
>> >> >> > >Could
>> not
>> >> >> find
>> >> >> > > error.additional.details.pancard.no
>> >> >> > >  
>> >> >> > > 
>> >> >> > >  
>> >> >> > >  
>> >> >> > >Could
>> >> not
>> >> >> > find
>> >> >> > > error.additional.details.passport.no!
>> >> >> > >  
>> >> >> > >
>> >> >> > > 
>> >> >> > >
>> >> >> > > 
>> >> >> > >
>> >> >> > > do i have to do something else to turn on validations?
>> >> >> > >
>> >> >> > >
>> >> >> > > *Thanks and Regards,*
>> >> >> > > Muralidhar Yaragalla.
>> >> >> > >
>> >> >> > > *http://yaragalla.blogspot.in/ *
>> >> >> > >
>> >> >> >
>> >> >>
>> >>
>> >>
>> >>
>> >> --
>> >> e: [email protected]
>> >> m: 908-380-8699
>> >> s: davelnewton_skype
>> >> t: @dave_newton
>> >> b: Bucky Bits
>> >> g: davelnewton
>> >> so: Dave Newton
>> >>
>> >> -
>> >> To unsubscribe, e-mail: [email protected]
>> >> For additional commands, e-mail: [email protected]
>> >>
>> >>
>>
>>
>>
>> --
>> e: [email protected]
>> m: 908-380-8699
>> s: davelnewton_skype
>> t: @dave_newton
>> b: Bucky Bits
>> g: davelnewton
>> so: Dave Newton
>>
>> -
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>
>


Re: validation problem

2014-12-25 Thread Dave Newton
Then you're doing something else wrong; never mind.

You still won't see the messages unless you display them manually.

On Thu, Dec 25, 2014 at 6:56 AM, Yaragalla Muralidhar
 wrote:
> in my case validations are not happenening . Even though validation fails
> it is moving to succeess rather than input jsp.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton  wrote:
>
>> Please read up on the themes.
>>
>> Nutshell: validation happens (this is trivially provable), validation
>> message display does not.
>>
>> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
>>  wrote:
>> > is it because of the simple theam? In simple theam validations dont
>> happen
>> > is it? if i dont use simple theme view components are generating their
>> own
>> > decoration. Our custom alignment is going wrong.
>> >
>> > *Thanks and Regards,*
>> > Muralidhar Yaragalla.
>> >
>> > *http://yaragalla.blogspot.in/ *
>> >
>> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton 
>> wrote:
>> >
>> >> Simple theme is simpler than you think.
>> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
>> [email protected]
>> >> >
>> >> wrote:
>> >>
>> >> > I am using struts2.3.20 and using simple theme.
>> >> >
>> >> > *Thanks and Regards,*
>> >> > Muralidhar Yaragalla.
>> >> >
>> >> > *http://yaragalla.blogspot.in/ *
>> >> >
>> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
>> >> > [email protected]> wrote:
>> >> >
>> >> > > Hi i am having problem in turning on validations. I have written
>> >> > > "actionClass-validation.xml" file in the same package as action
>> class.
>> >> > but
>> >> > > the validations are not working. the following is my validation xml
>> >> file.
>> >> > >
>> >> > > > >> 1.0.3//EN"
>> >> > > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
>> >> > > 
>> >> > >
>> >> > > 
>> >> > >  
>> >> > >Could
>> not
>> >> > find
>> >> > > error.additional.details.passport.no!
>> >> > >  
>> >> > >  
>> >> > >   
>> >> > >Could not
>> >> find
>> >> > > error.additional.details.pancard.no
>> >> > >  
>> >> > > 
>> >> > >  
>> >> > >  
>> >> > >Could
>> not
>> >> > find
>> >> > > error.additional.details.passport.no!
>> >> > >  
>> >> > >
>> >> > > 
>> >> > >
>> >> > > 
>> >> > >
>> >> > > do i have to do something else to turn on validations?
>> >> > >
>> >> > >
>> >> > > *Thanks and Regards,*
>> >> > > Muralidhar Yaragalla.
>> >> > >
>> >> > > *http://yaragalla.blogspot.in/ *
>> >> > >
>> >> >
>> >>
>>
>>
>>
>> --
>> e: [email protected]
>> m: 908-380-8699
>> s: davelnewton_skype
>> t: @dave_newton
>> b: Bucky Bits
>> g: davelnewton
>> so: Dave Newton
>>
>> -
>> To unsubscribe, e-mail: [email protected]
>> For additional commands, e-mail: [email protected]
>>
>>



-- 
e: [email protected]
m: 908-380-8699
s: davelnewton_skype
t: @dave_newton
b: Bucky Bits
g: davelnewton
so: Dave Newton

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
in my case validations are not happenening . Even though validation fails
it is moving to succeess rather than input jsp.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 6:15 PM, Dave Newton  wrote:

> Please read up on the themes.
>
> Nutshell: validation happens (this is trivially provable), validation
> message display does not.
>
> On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
>  wrote:
> > is it because of the simple theam? In simple theam validations dont
> happen
> > is it? if i dont use simple theme view components are generating their
> own
> > decoration. Our custom alignment is going wrong.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton 
> wrote:
> >
> >> Simple theme is simpler than you think.
> >> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" <
> [email protected]
> >> >
> >> wrote:
> >>
> >> > I am using struts2.3.20 and using simple theme.
> >> >
> >> > *Thanks and Regards,*
> >> > Muralidhar Yaragalla.
> >> >
> >> > *http://yaragalla.blogspot.in/ *
> >> >
> >> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
> >> > [email protected]> wrote:
> >> >
> >> > > Hi i am having problem in turning on validations. I have written
> >> > > "actionClass-validation.xml" file in the same package as action
> class.
> >> > but
> >> > > the validations are not working. the following is my validation xml
> >> file.
> >> > >
> >> > >  >> 1.0.3//EN"
> >> > > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
> >> > > 
> >> > >
> >> > > 
> >> > >  
> >> > >Could
> not
> >> > find
> >> > > error.additional.details.passport.no!
> >> > >  
> >> > >  
> >> > >   
> >> > >Could not
> >> find
> >> > > error.additional.details.pancard.no
> >> > >  
> >> > > 
> >> > >  
> >> > >  
> >> > >Could
> not
> >> > find
> >> > > error.additional.details.passport.no!
> >> > >  
> >> > >
> >> > > 
> >> > >
> >> > > 
> >> > >
> >> > > do i have to do something else to turn on validations?
> >> > >
> >> > >
> >> > > *Thanks and Regards,*
> >> > > Muralidhar Yaragalla.
> >> > >
> >> > > *http://yaragalla.blogspot.in/ *
> >> > >
> >> >
> >>
>
>
>
> --
> e: [email protected]
> m: 908-380-8699
> s: davelnewton_skype
> t: @dave_newton
> b: Bucky Bits
> g: davelnewton
> so: Dave Newton
>
> -
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


Re: validation problem

2014-12-25 Thread Dave Newton
Please read up on the themes.

Nutshell: validation happens (this is trivially provable), validation
message display does not.

On Thu, Dec 25, 2014 at 6:41 AM, Yaragalla Muralidhar
 wrote:
> is it because of the simple theam? In simple theam validations dont happen
> is it? if i dont use simple theme view components are generating their own
> decoration. Our custom alignment is going wrong.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton  wrote:
>
>> Simple theme is simpler than you think.
>> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" > >
>> wrote:
>>
>> > I am using struts2.3.20 and using simple theme.
>> >
>> > *Thanks and Regards,*
>> > Muralidhar Yaragalla.
>> >
>> > *http://yaragalla.blogspot.in/ *
>> >
>> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
>> > [email protected]> wrote:
>> >
>> > > Hi i am having problem in turning on validations. I have written
>> > > "actionClass-validation.xml" file in the same package as action class.
>> > but
>> > > the validations are not working. the following is my validation xml
>> file.
>> > >
>> > > > 1.0.3//EN"
>> > > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
>> > > 
>> > >
>> > > 
>> > >  
>> > >Could not
>> > find
>> > > error.additional.details.passport.no!
>> > >  
>> > >  
>> > >   
>> > >Could not
>> find
>> > > error.additional.details.pancard.no
>> > >  
>> > > 
>> > >  
>> > >  
>> > >Could not
>> > find
>> > > error.additional.details.passport.no!
>> > >  
>> > >
>> > > 
>> > >
>> > > 
>> > >
>> > > do i have to do something else to turn on validations?
>> > >
>> > >
>> > > *Thanks and Regards,*
>> > > Muralidhar Yaragalla.
>> > >
>> > > *http://yaragalla.blogspot.in/ *
>> > >
>> >
>>



-- 
e: [email protected]
m: 908-380-8699
s: davelnewton_skype
t: @dave_newton
b: Bucky Bits
g: davelnewton
so: Dave Newton

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
is it because of the simple theam? In simple theam validations dont happen
is it? if i dont use simple theme view components are generating their own
decoration. Our custom alignment is going wrong.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 5:05 PM, Dave Newton  wrote:

> Simple theme is simpler than you think.
> On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar"  >
> wrote:
>
> > I am using struts2.3.20 and using simple theme.
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
> > On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
> > [email protected]> wrote:
> >
> > > Hi i am having problem in turning on validations. I have written
> > > "actionClass-validation.xml" file in the same package as action class.
> > but
> > > the validations are not working. the following is my validation xml
> file.
> > >
> > >  1.0.3//EN"
> > > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
> > > 
> > >
> > > 
> > >  
> > >Could not
> > find
> > > error.additional.details.passport.no!
> > >  
> > >  
> > >   
> > >Could not
> find
> > > error.additional.details.pancard.no
> > >  
> > > 
> > >  
> > >  
> > >Could not
> > find
> > > error.additional.details.passport.no!
> > >  
> > >
> > > 
> > >
> > > 
> > >
> > > do i have to do something else to turn on validations?
> > >
> > >
> > > *Thanks and Regards,*
> > > Muralidhar Yaragalla.
> > >
> > > *http://yaragalla.blogspot.in/ *
> > >
> >
>


Re: validation problem

2014-12-25 Thread Dave Newton
Simple theme is simpler than you think.
On Dec 25, 2014 4:46 AM, "Yaragalla Muralidhar" 
wrote:

> I am using struts2.3.20 and using simple theme.
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>
> On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
> [email protected]> wrote:
>
> > Hi i am having problem in turning on validations. I have written
> > "actionClass-validation.xml" file in the same package as action class.
> but
> > the validations are not working. the following is my validation xml file.
> >
> >  > "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
> > 
> >
> > 
> >  
> >Could not
> find
> > error.additional.details.passport.no!
> >  
> >  
> >   
> >Could not find
> > error.additional.details.pancard.no
> >  
> > 
> >  
> >  
> >Could not
> find
> > error.additional.details.passport.no!
> >  
> >
> > 
> >
> > 
> >
> > do i have to do something else to turn on validations?
> >
> >
> > *Thanks and Regards,*
> > Muralidhar Yaragalla.
> >
> > *http://yaragalla.blogspot.in/ *
> >
>


Re: validation problem

2014-12-25 Thread Yaragalla Muralidhar
I am using struts2.3.20 and using simple theme.

*Thanks and Regards,*
Muralidhar Yaragalla.

*http://yaragalla.blogspot.in/ *

On Thu, Dec 25, 2014 at 4:08 PM, Yaragalla Muralidhar <
[email protected]> wrote:

> Hi i am having problem in turning on validations. I have written
> "actionClass-validation.xml" file in the same package as action class.  but
> the validations are not working. the following is my validation xml file.
>
>  "http://struts.apache.org/dtds/xwork-validator-1.0.3.dtd";>
> 
>
> 
>  
>Could not find
> error.additional.details.passport.no!
>  
>  
>   
>Could not find
> error.additional.details.pancard.no
>  
> 
>  
>  
>Could not find
> error.additional.details.passport.no!
>  
>
> 
>
> 
>
> do i have to do something else to turn on validations?
>
>
> *Thanks and Regards,*
> Muralidhar Yaragalla.
>
> *http://yaragalla.blogspot.in/ *
>


Re: Validation Problem

2010-10-09 Thread Maurizio Cucchiara
It's a know bug.
If your application doesn't run in a production environment  you could
download latest struts release from
https://hudson.apache.org/hudson/view/Struts/job/struts2/

Maurizio Cucchiara

2010/10/9 Chris Miles :
> Whenever the validation procedure returns to the "input" result, any
>  anything which needs to be configured or toggled to allow it?
>
>
>
> Thanks
>
>
>
> Chris
>
>

-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: Validation problem when navigating through pages

2009-02-10 Thread Srikanth Goud


Sorry i have done blunder.There is no such issue

Srikanth



Srikanth Goud wrote:
> 
> Hi,
> 
>I was using default theme before.But to gain full control on UI part i
> chaged to simple theme.
>Know the problem is 
> I performed business logic in one the screen. If it is success than
> the next screen in cycle.
> But the validations are firing in the next screen.It should not fire
> when the page render for the first time.
> 
>  And my code is
> 
>  In jsp
> 
>  
>   
> deposits  and
> so on...
> 
> struts.xml
> 
>   class="com.ulms.action.BankInternalDetails">
>   internalDetails.def
>   customerInfo.def
> 
> 
> these internalDetails.def and customerInfo.def are definations in
> tiles.xml
> 
> could u please tell what is the mistake?
> and how to stop validations when page renders for first time?
> 
> regards
> Srikanth.
> 
> 
>
> 

-- 
View this message in context: 
http://www.nabble.com/Validation-problem-when-navigating-through-pages-tp21933765p21934405.html
Sent from the Struts - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]



Re: validation problem

2008-09-30 Thread Sébastien Domergue

Hi,

if you use xml validation, you should use  a validator like this one :


mySelectBox
0
Please select a value


As your default value is -1, the validator will only check if the value 
is not -1. For the rest of the values, there won't be any other check.


If you use annotation validation, there is a very similar way to define 
that even if i didn't use it (so i won't try to write something).


Hope i helped you

Regards

Sébastien

Naag a écrit :

hi to everybody...

i am getting the problem with validating the filed which contains the drop
down box. from the box we can select the item to the field.
the headerkey="-1" header value="select one item".
how to validate these type of fileds.


my problem is---?

if didn't select any item from the dropdown box,then the default value is
---select One item

if the filed contains the select one item,then how validate this one from
validation.xml file?
if have been selected any one of the items,no validation is required.
jsp


-action class variable
private List groupNames = new ArrayList();


please send me the clue for this one.
i tried in all the ways,but i am helpless

Thanking u



  


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: validation problem

2008-06-26 Thread Laurie Harper
Why not just validate all fields with type="requiredstring" and set 
short-circuit="true" on them? Wouldn't that do what you want? See the 
Short-Circuiting Validator section of the validation docs [1] for more 
details.


[1] http://struts.apache.org/2.1.2/docs/validation.html

L.

ManiKanta G wrote:

Hi,

Even I've this problem... Here is my requirement

I've 3 fields. On successful validation of 1st field ONLY the 2nd field 
should be validated, and only with the successful validation of second, 
then only the 3rd field should be validated against some validation.


I did this by using field validator of type expression, like below...

   *
   
   
   Select 'Return to'
   
   

   
   
   
   
   Select company/dealer name
 

   
   
   
   
   Select drug
   
   

   *

With this, the second case working as it supposed. The second field will 
be validated ONLY when the first field is not empty (as in the second 
field expression, I m using */returnTo == null/* with short-circuit OR, 
and then the actual validation logic of second field).


But the validation logic of the third field (select box) is not working 
as is supposed to. When I print the expression value using *value="expression_of_the_third_field_."/>*, it is printing false, 
but the validation is being bypassed.


I've tried many ways. But non of 'em worked for me. Is any one got 
success with this type of validations.


I can implement custom validation using validate(), but I've around 30 
transactional forms with this type of requirements.


Am I doing any this wrong? Can anybody please guide me with this...


Thanks,
ManiKanta



Dave Newton wrote:
You either do conditional validations, implement custom validators, or 
as Lukasz suggested write your own validate() method. When validation 
is very complex the last may be the best options.


Dave

--- On Wed, 6/25/08, Istvan Kozma <[EMAIL PROTECTED]> wrote:
 

How the validation should be done for fields which are only
displayed in certain conditions? If  I do this through the
XML file the validation is done all the time even when the
field is not visible.
Istvan


- Original Message 
From: Dave Newton <[EMAIL PROTECTED]>
To: Struts Users Mailing List

Sent: Wednesday, June 25, 2008 3:37:38 PM
Subject: Re: validation problem

Whoops, as the other reply said, it's the
 tag [1], not .

Dave

[1] http://struts.apache.org/2.x/docs/fielderror.html

--- On Wed, 6/25/08, Dave Newton
<[EMAIL PROTECTED]> wrote:
   

--- On Wed, 6/25/08, Anshu Dhamija wrote:
 

i am facing problem in performing validation


through
   

xml actually i want to display message at the top

of

my form instaed of at field level can anyone please help me


The validation messages are placed in the form by the
  

S2
   

form element tags. If you want to modify the output of
those tags you can modify or create a theme [1].

Using the "simple" theme will also remove
  

the
   

validation messages, but you'll lose other useful
functionality--but that might not be an issue
  

depending on
   

your usecase.

The  tag [2] will render any
  

error
   

messages. A combination of either the simple theme or
  

a
   

modified theme plus the action error tag may do what
  

you
   

need.

Dave

[1]

  

http://struts.apache.org/2.x/docs/themes-and-templates.html
   

[2] http://struts.apache.org/2.x/docs/actionerror.html
  

-
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]

  





** DISCLAIMER **
Information contained and transmitted by this E-MAIL is proprietary to 
Sify Limited and is intended for use only by the individual or entity to 
which it is addressed, and may contain information that is privileged, 
confidential or exempt from disclosure under applicable law. If this is 
a forwarded message, the content of this E-MAIL may not have been sent 
with the authority of the Company. If you are not the intended 
recipient, an agent of the intended recipient or a  person responsible 
for delivering the information to the named recipient,  you are notified 
that any use, distribution, transmission, printing, copying or 
dissemination of this information in any way or in any manner is 
strictly prohibited. If you have received this communication in error, 
please delete this mail & notify us immediately at [EMAIL PROTECTED]






Re: validation problem

2008-06-25 Thread Lukasz Lenart
> I can implement custom validation using validate(), but I've around 30
> transactional forms with this type of requirements.

Maybe it will be better if you implement your own validator for thoese
30 forms? I think it will be soft option then very compilcated
expression above ;-)


Regards
-- 
Lukasz
http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: validation problem

2008-06-25 Thread ManiKanta G

Hi,

Even I've this problem... Here is my requirement

I've 3 fields. On successful validation of 1st field ONLY the 2nd field 
should be validated, and only with the successful validation of second, 
then only the 3rd field should be validated against some validation.


I did this by using field validator of type expression, like below...

   *
   
   
   Select 'Return to'
   
   

   
   
   
   
   Select company/dealer name
  
   


   
   
   
   
   Select drug
   
   

   *

With this, the second case working as it supposed. The second field will 
be validated ONLY when the first field is not empty (as in the second 
field expression, I m using */returnTo == null/* with short-circuit OR, 
and then the actual validation logic of second field).


But the validation logic of the third field (select box) is not working 
as is supposed to. When I print the expression value using *value="expression_of_the_third_field_."/>*, it is printing false, 
but the validation is being bypassed.


I've tried many ways. But non of 'em worked for me. Is any one got 
success with this type of validations.


I can implement custom validation using validate(), but I've around 30 
transactional forms with this type of requirements.


Am I doing any this wrong? Can anybody please guide me with this...


Thanks,
ManiKanta



Dave Newton wrote:

You either do conditional validations, implement custom validators, or as 
Lukasz suggested write your own validate() method. When validation is very 
complex the last may be the best options.

Dave

--- On Wed, 6/25/08, Istvan Kozma <[EMAIL PROTECTED]> wrote:
  

How the validation should be done for fields which are only
displayed in certain conditions? If  I do this through the
XML file the validation is done all the time even when the
field is not visible. 


Istvan


- Original Message 
From: Dave Newton <[EMAIL PROTECTED]>
To: Struts Users Mailing List

Sent: Wednesday, June 25, 2008 3:37:38 PM
Subject: Re: validation problem

Whoops, as the other reply said, it's the
 tag [1], not .

Dave

[1] http://struts.apache.org/2.x/docs/fielderror.html

--- On Wed, 6/25/08, Dave Newton
<[EMAIL PROTECTED]> wrote:


--- On Wed, 6/25/08, Anshu Dhamija wrote:
  

i am facing problem in performing validation


through


xml actually i want to display message at the top

of 

my form instaed of at field level 
can anyone please help me


The validation messages are placed in the form by the
  

S2


form element tags. If you want to modify the output of
those tags you can modify or create a theme [1].

Using the "simple" theme will also remove
  

the


validation messages, but you'll lose other useful
functionality--but that might not be an issue
  

depending on


your usecase.

The  tag [2] will render any
  

error


messages. A combination of either the simple theme or
  

a


modified theme plus the action error tag may do what
  

you


need.

Dave

[1]

  

http://struts.apache.org/2.x/docs/themes-and-templates.html


[2] http://struts.apache.org/2.x/docs/actionerror.html
  

-
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]

  





** DISCLAIMER **
Information contained and transmitted by this E-MAIL is proprietary to 
Sify Limited and is intended for use only by the individual or entity to 
which it is addressed, and may contain information that is privileged, 
confidential or exempt from disclosure under applicable law. If this is a 
forwarded message, the content of this E-MAIL may not have been sent with 
the authority of the Company. If you are not the intended recipient, an 
agent of the intended recipient or a  person responsible for delivering the 
information to the named recipient,  you are notified that any use, 
distribution, transmission, printing, copying or dissemination of this 
information in any way or in any manner is strictly prohibited. If you have 
received this communication in error, please delete this mail & notify us 
immediately at [EMAIL PROTECTED]


Re: validation problem

2008-06-25 Thread Dave Newton
You either do conditional validations, implement custom validators, or as 
Lukasz suggested write your own validate() method. When validation is very 
complex the last may be the best options.

Dave

--- On Wed, 6/25/08, Istvan Kozma <[EMAIL PROTECTED]> wrote:
> How the validation should be done for fields which are only
> displayed in certain conditions? If  I do this through the
> XML file the validation is done all the time even when the
> field is not visible. 
> 
> Istvan
> 
> 
> - Original Message 
> From: Dave Newton <[EMAIL PROTECTED]>
> To: Struts Users Mailing List
> 
> Sent: Wednesday, June 25, 2008 3:37:38 PM
> Subject: Re: validation problem
> 
> Whoops, as the other reply said, it's the
>  tag [1], not .
> 
> Dave
> 
> [1] http://struts.apache.org/2.x/docs/fielderror.html
> 
> --- On Wed, 6/25/08, Dave Newton
> <[EMAIL PROTECTED]> wrote:
> > --- On Wed, 6/25/08, Anshu Dhamija wrote:
> > > i am facing problem in performing validation
> through
> > > xml actually i want to display message at the top
> of 
> > > my form instaed of at field level 
> > > can anyone please help me
> > 
> > The validation messages are placed in the form by the
> S2
> > form element tags. If you want to modify the output of
> > those tags you can modify or create a theme [1].
> > 
> > Using the "simple" theme will also remove
> the
> > validation messages, but you'll lose other useful
> > functionality--but that might not be an issue
> depending on
> > your usecase.
> > 
> > The  tag [2] will render any
> error
> > messages. A combination of either the simple theme or
> a
> > modified theme plus the action error tag may do what
> you
> > need.
> > 
> > Dave
> > 
> > [1]
> >
> http://struts.apache.org/2.x/docs/themes-and-templates.html
> > [2] http://struts.apache.org/2.x/docs/actionerror.html
> 
> 
> -
> 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: validation problem

2008-06-25 Thread Lukasz Lenart
Hi,

> How the validation should be done for fields which are only displayed in 
> certain conditions? If  I do this through the XML file the validation is done 
> all the time even when the field is not visible.

You can implement validate() or validate() and remember
to implement Validatable interface.
http://struts.apache.org/2.1.2/docs/validation.html


Regards
-- 
Lukasz
http://www.lenart.org.pl/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: validation problem

2008-06-25 Thread Istvan Kozma
Hi,

How the validation should be done for fields which are only displayed in 
certain conditions? If  I do this through the XML file the validation is done 
all the time even when the field is not visible. 

Istvan


- Original Message 
From: Dave Newton <[EMAIL PROTECTED]>
To: Struts Users Mailing List 
Sent: Wednesday, June 25, 2008 3:37:38 PM
Subject: Re: validation problem

Whoops, as the other reply said, it's the  tag [1], not 
.

Dave

[1] http://struts.apache.org/2.x/docs/fielderror.html

--- On Wed, 6/25/08, Dave Newton <[EMAIL PROTECTED]> wrote:
> --- On Wed, 6/25/08, Anshu Dhamija wrote:
> > i am facing problem in performing validation through
> > xml actually i want to display message at the top of 
> > my form instaed of at field level 
> > can anyone please help me
> 
> The validation messages are placed in the form by the S2
> form element tags. If you want to modify the output of
> those tags you can modify or create a theme [1].
> 
> Using the "simple" theme will also remove the
> validation messages, but you'll lose other useful
> functionality--but that might not be an issue depending on
> your usecase.
> 
> The  tag [2] will render any error
> messages. A combination of either the simple theme or a
> modified theme plus the action error tag may do what you
> need.
> 
> Dave
> 
> [1]
> http://struts.apache.org/2.x/docs/themes-and-templates.html
> [2] http://struts.apache.org/2.x/docs/actionerror.html


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  

Re: validation problem

2008-06-25 Thread Dave Newton
Whoops, as the other reply said, it's the  tag [1], not 
.

Dave

[1] http://struts.apache.org/2.x/docs/fielderror.html

--- On Wed, 6/25/08, Dave Newton <[EMAIL PROTECTED]> wrote:
> --- On Wed, 6/25/08, Anshu Dhamija wrote:
> > i am facing problem in performing validation through
> > xml actually i want to display message at the top of 
> > my form instaed of at field level 
> > can anyone please help me
> 
> The validation messages are placed in the form by the S2
> form element tags. If you want to modify the output of
> those tags you can modify or create a theme [1].
> 
> Using the "simple" theme will also remove the
> validation messages, but you'll lose other useful
> functionality--but that might not be an issue depending on
> your usecase.
> 
> The  tag [2] will render any error
> messages. A combination of either the simple theme or a
> modified theme plus the action error tag may do what you
> need.
> 
> Dave
> 
> [1]
> http://struts.apache.org/2.x/docs/themes-and-templates.html
> [2] http://struts.apache.org/2.x/docs/actionerror.html


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: validation problem

2008-06-25 Thread ManiKanta G

Anshu Dhamija wrote:

hi
   i am new to struts 2.i am facing problem in performing validation through
xml
actually i want to display message at the top of my form instaed of at field
level
can anyone please help me

  

Hi,

In struts2 there is a provision for handling the error messages by field 
and action level.


If the message u want to display is not related to any particular field, 
then u can use ** tag at the top of ur page.


If the validation message is particular to a field, u can use 
** tag at the top of the page. This will displays all 
the field validation errors.
To display validation errors specific to a field, use * 
tag with *, like below


   *
   */fieldName/*
   *

Like this u can place individual field errors in ur custom layout in ur 
way, using tables, divs or something else.


When you explore the validation framework, what u see is more types of 
validation, which includes field validatiors & non-field validators.


Field validators are specific to a field, and thus adds a field error.
Non-field validators are NOT specific to any single field and thus the 
error message will be added as action level error (action error).


U can get more info regarding validations from Struts2 documentation.

Feel free to ask if u've need any clarification.

Regards,
ManiKanta G




** DISCLAIMER **
Information contained and transmitted by this E-MAIL is proprietary to 
Sify Limited and is intended for use only by the individual or entity to 
which it is addressed, and may contain information that is privileged, 
confidential or exempt from disclosure under applicable law. If this is a 
forwarded message, the content of this E-MAIL may not have been sent with 
the authority of the Company. If you are not the intended recipient, an 
agent of the intended recipient or a  person responsible for delivering the 
information to the named recipient,  you are notified that any use, 
distribution, transmission, printing, copying or dissemination of this 
information in any way or in any manner is strictly prohibited. If you have 
received this communication in error, please delete this mail & notify us 
immediately at [EMAIL PROTECTED]


Re: validation problem

2008-06-25 Thread Dave Newton
--- On Wed, 6/25/08, Anshu Dhamija <[EMAIL PROTECTED]> wrote:
> i am facing problem in performing validation through
> xml actually i want to display message at the top of 
> my form instaed of at field level 
> can anyone please help me

The validation messages are placed in the form by the S2 form element tags. If 
you want to modify the output of those tags you can modify or create a theme 
[1].

Using the "simple" theme will also remove the validation messages, but you'll 
lose other useful functionality--but that might not be an issue depending on 
your usecase.

The  tag [2] will render any error messages. A combination of 
either the simple theme or a modified theme plus the action error tag may do 
what you need.

Dave

[1] http://struts.apache.org/2.x/docs/themes-and-templates.html
[2] http://struts.apache.org/2.x/docs/actionerror.html


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: validation problem

2008-05-12 Thread Laurie Harper

Anet wrote:

Hi everybody;
  I have some tables on my page. each of them contains some of properties. for 
the first time, tables are hidden and will be displayed by this javascript code:
  function toggle(id){
 var id = id;
 var table = document.getElementById(id);
 if(table.style.display=="none"){
  table.style.display="";
 }else if (table.style.display==""){
  table.style.display="none";
 }
}
  and in my jsp page for example:
  
  
   
   some property here
   

  they will be shown by clicking on the image.(down_enabled.gif)
  The struts validation works on my form correctly.but I want when a property is in one 
of these tables and the validator returns "false" on it, the table will be 
shown. I don't know how to use result of validation? any idea?


I see an html:img tag in there, so I'm assuming you're using Struts 1. 
You can use the messagesPresent tag [1] to conditionally include a 

Re: Validation Problem

2007-12-11 Thread Arpan Debroy
Which validators you used for the two fields, which are getting validated
rightly?
I am facing similar situation that whenever you use "required" validator,
it'll not work.
So for the string field you have to use "requiredstring" validator.
For number, specially which have "long" data type, I am not sure how to
validate for empty field.

On Dec 11, 2007 12:56 PM, ginu george <[EMAIL PROTECTED]> wrote:

> This are the two Fields get validated
>  cssClass="text medium" />
>  id="postingAppDate"key="externalPosting.postingApplicationDate"
> required="true" cssClass="text medium" />
>
> Field which are not getting Validated
>
>
>  cssClass="text medium" />
> required="true" cssClass="text medium" />
> required="true" cssClass="text medium" />
>
>
> Ginu
>
>
> On Tue, 2007-12-11 at 11:30 +0530, Arpan Debroy wrote:
> > Which are the two fields are getting validated and which are not..
> >
> > On Dec 11, 2007 10:17 AM, <[EMAIL PROTECTED]> wrote:
> >
> > > iam using struts2 iam getting a validation Problem
> > > All the fields get Validated while using the get method for a
> particular
> > > action while using the post method (using  5 Fields)only two fields
> get
> > > validated
> > >
> > >
> > >
> > > In jsp
> > >
> > >required="true"
> > > cssClass="text medium" />
> > > > > required="true" cssClass="text medium" />
> > > required="true"
> > > cssClass="text medium" />
> > >
> > >
> > > in validation.xml
> > >
> > >
> > >  
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > 
> > > 
> > > 
> > > 
> > >
> > > in struts.xml
> > >   > > method="execute">
> > >
> > > /WEB-INF/pages/folio/folioSpecificPostingListPage.jsp
> > >  > > name="input">/WEB-INF/pages/folio/externalPosting.jsp
> > >
> > >
> > > Ginu
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >  Please put some more inputs.
> > > >
> > > > On Dec 8, 2007 12:40 PM, <[EMAIL PROTECTED]> wrote:
> > > >
> > > >>
> > > >>
> > > >> Hi all
> > > >>
> > > >> iam using struts2 iam getting a validation Problem
> > > >> All the fields get Validated while using the get method for a
> > > particular
> > > >> action while using the post method only two fields get validated
> > > >>
> > > >> Ginu
> > > >>
> > > >>
> -
> > > >>
> > >
> > > -
> > > 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]
>
>


-- 
Thanks & Regards
 Arpan Debroy

AOL Online India Private Ltd
RMZ EcoSpace Campus 1A
Outer Ring Road, Bellandur,
Bangalore - 560037
India
Mobile No :+9886006306
on-board :+91 (80) 4035 4528
E-mail : [EMAIL PROTECTED]


Re: Validation Problem

2007-12-10 Thread ginu george
This are the two Fields get validated



Field which are not getting Validated







Ginu


On Tue, 2007-12-11 at 11:30 +0530, Arpan Debroy wrote:
> Which are the two fields are getting validated and which are not..
> 
> On Dec 11, 2007 10:17 AM, <[EMAIL PROTECTED]> wrote:
> 
> > iam using struts2 iam getting a validation Problem
> > All the fields get Validated while using the get method for a particular
> > action while using the post method (using  5 Fields)only two fields get
> > validated
> >
> >
> >
> > In jsp
> >
> >> cssClass="text medium" />
> > > required="true" cssClass="text medium" />
> > > cssClass="text medium" />
> >
> >
> > in validation.xml
> >
> >
> >  
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > 
> > 
> > 
> > 
> >
> > in struts.xml
> >   > method="execute">
> >
> > /WEB-INF/pages/folio/folioSpecificPostingListPage.jsp
> >  > name="input">/WEB-INF/pages/folio/externalPosting.jsp
> >
> >
> > Ginu
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >  Please put some more inputs.
> > >
> > > On Dec 8, 2007 12:40 PM, <[EMAIL PROTECTED]> wrote:
> > >
> > >>
> > >>
> > >> Hi all
> > >>
> > >> iam using struts2 iam getting a validation Problem
> > >> All the fields get Validated while using the get method for a
> > particular
> > >> action while using the post method only two fields get validated
> > >>
> > >> Ginu
> > >>
> > >> -
> > >>
> >
> > -
> > 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: Validation Problem

2007-12-10 Thread ginu
Hi Jerome,
   I have created a new thread.  I never did reply to any e-mail when
composing this email.  However I did reply to a reply I could have got.
   This problem could have been caused by both the threads having the same
subject.  It is unintentional.
   Ginu.

> [EMAIL PROTECTED] wrote:
>> Hi all
>>
>> iam using struts2 iam getting a validation Problem
>> All the fields get Validated while using the get method for a particular
>> action while using the post method only two fields get validated
>>
>> Ginu
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>
> Hi Ginu, in the future try not to 'hijack' the thread of another user.
> The original poster (Adi) was asking about Struts 1 validation but you
> took over his thread (and subject) to ask about your own struts2
> validation problem, which means Adi's original question is essentially
> lost in the noise.  It's not very courteous to do that.
>
> Next time, create a new thread by composing a new message instead of
> replying to an existing one.  It also helps to change the subject.
>
> Thanks,
>  Jeromy Evans
>
> PS. I don't know the answer to Adi's question nor your's.
>
> -
> 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: Validation Problem

2007-12-10 Thread Arpan Debroy
Which are the two fields are getting validated and which are not..

On Dec 11, 2007 10:17 AM, <[EMAIL PROTECTED]> wrote:

> iam using struts2 iam getting a validation Problem
> All the fields get Validated while using the get method for a particular
> action while using the post method (using  5 Fields)only two fields get
> validated
>
>
>
> In jsp
>
>cssClass="text medium" />
> required="true" cssClass="text medium" />
> cssClass="text medium" />
>
>
> in validation.xml
>
>
>  
> 
> 
> 
> 
>
> 
> 
> 
> 
>
> 
> 
> 
> 
>
> in struts.xml
>   method="execute">
>
> /WEB-INF/pages/folio/folioSpecificPostingListPage.jsp
>  name="input">/WEB-INF/pages/folio/externalPosting.jsp
>
>
> Ginu
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>  Please put some more inputs.
> >
> > On Dec 8, 2007 12:40 PM, <[EMAIL PROTECTED]> wrote:
> >
> >>
> >>
> >> Hi all
> >>
> >> iam using struts2 iam getting a validation Problem
> >> All the fields get Validated while using the get method for a
> particular
> >> action while using the post method only two fields get validated
> >>
> >> Ginu
> >>
> >> -
> >>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Thanks & Regards
 Arpan Debroy

AOL Online India Private Ltd
RMZ EcoSpace Campus 1A
Outer Ring Road, Bellandur,
Bangalore - 560037
India
Mobile No :+9886006306
on-board :+91 (80) 4035 4528
E-mail : [EMAIL PROTECTED]


Re: Validation Problem

2007-12-10 Thread Jeromy Evans

[EMAIL PROTECTED] wrote:

Hi all

iam using struts2 iam getting a validation Problem
All the fields get Validated while using the get method for a particular
action while using the post method only two fields get validated

Ginu

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  


Hi Ginu, in the future try not to 'hijack' the thread of another user.  
The original poster (Adi) was asking about Struts 1 validation but you 
took over his thread (and subject) to ask about your own struts2 
validation problem, which means Adi's original question is essentially 
lost in the noise.  It's not very courteous to do that.


Next time, create a new thread by composing a new message instead of 
replying to an existing one.  It also helps to change the subject.


Thanks,
Jeromy Evans

PS. I don't know the answer to Adi's question nor your's.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2007-12-10 Thread ginu
iam using struts2 iam getting a validation Problem
All the fields get Validated while using the get method for a particular
action while using the post method (using  5 Fields)only two fields get
validated



In jsp

   




in validation.xml


 
 
 
 
 

 
 
 
 

 
 
 
 

in struts.xml
 
 
/WEB-INF/pages/folio/folioSpecificPostingListPage.jsp
 /WEB-INF/pages/folio/externalPosting.jsp


Ginu
















 Please put some more inputs.
>
> On Dec 8, 2007 12:40 PM, <[EMAIL PROTECTED]> wrote:
>
>>
>>
>> Hi all
>>
>> iam using struts2 iam getting a validation Problem
>> All the fields get Validated while using the get method for a particular
>> action while using the post method only two fields get validated
>>
>> Ginu
>>
>> -
>>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2007-12-09 Thread Arpan Debroy
Please put some more inputs.

On Dec 8, 2007 12:40 PM, <[EMAIL PROTECTED]> wrote:

>
>
> Hi all
>
> iam using struts2 iam getting a validation Problem
> All the fields get Validated while using the get method for a particular
> action while using the post method only two fields get validated
>
> Ginu
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Thanks & Regards
 Arpan Debroy

AOL Online India Private Ltd
RMZ EcoSpace Campus 1A
Outer Ring Road, Bellandur,
Bangalore - 560037
India
Mobile No :+9886006306
on-board :+91 (80) 4035 4528
E-mail : [EMAIL PROTECTED]


RE: Validation problem - key not found?

2007-10-09 Thread Dean Pullen
I've tried adding a package.properties with the same key but nothing
seems to help - I still seem to get the same exception.

Anyone?

-Original Message-
From: Dean Pullen [mailto:[EMAIL PROTECTED] 
Sent: 09 October 2007 18:08
To: Struts Users Mailing List
Subject: Validation problem - key not found?

 

Hi all.

 

Trying to do this:

 

@RequiredStringValidator(message = "Hello", key = "Hello.key")

public String getQuestion1Option()

{

return question1Option;

}

 

 

But receiving this error on submission of the action:

 

[09 Oct 2007 17:54:46] ERROR
org.apache.catalina.core.ContainerBase.[jboss.web].

[localhost].[/csi].[default]  - Servlet.service() for servlet default
threw exce

ption

java.lang.NullPointerException

at
com.opensymphony.xwork2.util.LocalizedTextUtil.createMissesKey(Locali

zedTextUtil.java:240)

at
com.opensymphony.xwork2.util.LocalizedTextUtil.findResourceBundle(Loc

alizedTextUtil.java:219)

at
com.opensymphony.xwork2.util.LocalizedTextUtil.getMessage(LocalizedTe

xtUtil.java:602)

at
com.opensymphony.xwork2.util.LocalizedTextUtil.findMessage(LocalizedT

extUtil.java:643)

at
com.opensymphony.xwork2.util.LocalizedTextUtil.findText(LocalizedText

Util.java:360)

at
com.opensymphony.xwork2.util.LocalizedTextUtil.findText(LocalizedText

Util.java:293)

at
com.opensymphony.xwork2.TextProviderSupport.getText(TextProviderSuppo

rt.java:173)

at
com.opensymphony.xwork2.TextProviderSupport.getText(TextProviderSuppo

rt.java:104)

at
com.opensymphony.xwork2.ActionSupport.getText(ActionSupport.java:75)

at
com.opensymphony.xwork2.validator.DelegatingValidatorContext.getText(

DelegatingValidatorContext.java:106)

at
com.opensymphony.xwork2.validator.validators.ValidatorSupport.getMess

age(ValidatorSupport.java:66)

at
com.opensymphony.xwork2.validator.validators.ValidatorSupport.addFiel

dError(ValidatorSupport.java:162)

at
com.opensymphony.xwork2.validator.validators.RequiredStringValidator.

validate(RequiredStringValidator.java:77)

 

etc

 

 

Any idea what's wrong? The key is in my struts-messages.properties and
struts-messages_en.properties

 

Cheers



Scanned by MailDefender - managed email security from intY -
www.maildefender.net

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2006-11-09 Thread Li

Hi, Niall,

Problem solved. That's cuz I was trying to forward to another customized
action. I had made this action as ForwardAction provided by Struts. It works
now. Thanks. Sorry I was a bit rush writing the previously email so that
forgot to put the version number.

Regards

Li

On 11/10/06, Niall Pemberton <[EMAIL PROTECTED]> wrote:


Look at where you're directing the action to go to if an error occurs
- i.e. what have you specified as you're "input" for the action in
your struts-config.xml?

It looks like the error occured after validation failed and when it
tried to forward to whatever was specified in the "input" parameter.

Niall

P.S. Its always useful to post the version number of Struts you're using.

On 11/9/06, Li <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I met very wired problem. A have a DynaValidatorForm which is assigned
to an
> action. When I didnt put this form to validation.xml. It works fine.
When I
> put this into validation.xml in order to validate "Empty Entry
Situation" It
> throws exception:
>
> javax.servlet.ServletException: Action[/QICSampleStatusChecker] does
> not contain specified method (check logs)
> org.apache.struts.action.RequestProcessor.processException(
RequestProcessor.java:535)
> org.apache.struts.action.RequestProcessor.processActionPerform(
RequestProcessor.java:433)
> org.apache.struts.action.RequestProcessor.process(
RequestProcessor.java:236)
> org.apache.struts.action.ActionServlet.process(
ActionServlet.java:1196)
> org.apache.struts.action.ActionServlet.doPost(ActionServlet.java
:432)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> org.apache.struts.action.RequestProcessor.doForward(
RequestProcessor.java:1085)
> org.apache.struts.tiles.TilesRequestProcessor.doForward(
TilesRequestProcessor.java:263)
>
org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(
RequestProcessor.java:1023)
>
org.apache.struts.tiles.TilesRequestProcessor.internalModuleRelativeForward
(TilesRequestProcessor.java:345)
> org.apache.struts.action.RequestProcessor.processValidate(
RequestProcessor.java:988)
> org.apache.struts.action.RequestProcessor.process(
RequestProcessor.java:207)
> org.apache.struts.action.ActionServlet.process(
ActionServlet.java:1196)
> org.apache.struts.action.ActionServlet.doPost(ActionServlet.java
:432)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>
> I was wondering what was going on. I applied this in many places of my
> application, never meet such problem like this.
> Any idea?
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
When we invent time, we invent death.


Re: Validation problem

2006-11-09 Thread Niall Pemberton

Look at where you're directing the action to go to if an error occurs
- i.e. what have you specified as you're "input" for the action in
your struts-config.xml?

It looks like the error occured after validation failed and when it
tried to forward to whatever was specified in the "input" parameter.

Niall

P.S. Its always useful to post the version number of Struts you're using.

On 11/9/06, Li <[EMAIL PROTECTED]> wrote:

Hi all,

I met very wired problem. A have a DynaValidatorForm which is assigned to an
action. When I didnt put this form to validation.xml. It works fine. When I
put this into validation.xml in order to validate "Empty Entry Situation" It
throws exception:

javax.servlet.ServletException: Action[/QICSampleStatusChecker] does
not contain specified method (check logs)

org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:535)

org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:433)

org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1085)

org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:263)

org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(RequestProcessor.java:1023)

org.apache.struts.tiles.TilesRequestProcessor.internalModuleRelativeForward(TilesRequestProcessor.java:345)

org.apache.struts.action.RequestProcessor.processValidate(RequestProcessor.java:988)

org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:207)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

I was wondering what was going on. I applied this in many places of my
application, never meet such problem like this.
Any idea?




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Validation Problem

2006-05-21 Thread Paul Benedict
Remember that your validation rules are written in XML, so you must
follow XML rules: escape less-than signs, greater-than, and ampersand.
If you don't like this, you can always wrap them in CDATA sections:







--- Albrecht Leiprecht <[EMAIL PROTECTED]> wrote:

> 
> >If fails, because the test line for validwhen is not wellformed, because of
> >this comparation
> 
> >(*this* < 300)
> 
> It works fine with a check for greaterThan, but it fails with the above
> lowerThan...
> 
> >Any Idea how I could change it to make it work ??
> 
> >Rgds
> >Albi
> 
> I changed this
> 
> (*this* < 300)
> 
> To
> 
> (*this* < 300)
> 
> And it seems to work ;) Live can be so easy ;)
> 
> Thanks anyway
> 
> Rgds
> albi
> 
> 
> -
> 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: Validation Problem

2006-05-21 Thread Albrecht Leiprecht

>If fails, because the test line for validwhen is not wellformed, because of
>this comparation

>(*this* < 300)

It works fine with a check for greaterThan, but it fails with the above
lowerThan...

>Any Idea how I could change it to make it work ??

>Rgds
>Albi

I changed this

(*this* < 300)

To

(*this* < 300)

And it seems to work ;) Live can be so easy ;)

Thanks anyway

Rgds
albi


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-28 Thread Thibaut

Hi

i found the solution i was looking for : 
http://wiki.apache.org/struts/StrutsDeprecatedActionErrors

Thank you for those who tried to help me.

Thibaut Lassalle

Thibaut a écrit :


Hi

I have all the time the same problem and there is a week i try to 
solve it. It should be trivial but i can't see.

None of my validation work !
I now use Struts 1.2.8 with module. The application use to work with 
Struts 1.0.


In the Struts-config.xml of the "user" module :

 
type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"

  input="missions_copyMailToBasket.jsp"
  name="candidateForm"
  scope="request"
  validate="false">
  
  
   
...

 
 parameter="com.cvdunet.controller.ApplicationResources"/>




In the action :

   CandidateForm candidateForm = (CandidateForm) form;
   ActionMessages errors = candidateForm.validate();
   if (!errors.isEmpty()) {
   this.saveErrors(request, errors);
   return mapping.getInputForward();
   }



And in the form :

public ActionMessages validate()
{
ActionMessages errors  = new ActionMessages();
ActionMessage error = new 
ActionMessage(CandidateConstant.NO_BASKET);

errors.add(ActionMessages.GLOBAL_MESSAGE, error);
return errors;
   }


Can anyone help ?
Thank you



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-23 Thread Thibaut



Dave Newton a écrit :


Thibaut wrote:
 


In the WEB-INF/user/struts-config.xml

  
type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"

 input="essai.html"
   



Your input page is an HTML file?
 


Yes it's just to test my "return mapping.getInputForward();" function.
But it does'nt seem to work ...

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Dave Newton
Thibaut wrote:
> In the WEB-INF/user/struts-config.xml
>
>  
> type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
>   input="essai.html"

Your input page is an HTML file?

Dave



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Thibaut

Hi

I did what you tell me to do. Here is the simpliest thing that does'nt 
work :

In the WEB-INF/user/struts-config.xml

 
type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"

  input="essai.html"
  name="candidateForm"
  scope="request"
  validate="false">
  
  
   
  


In the very first line of the action

public class UpdateResponsesForRequestAction extends Action
{
   public ActionForward execute(ActionMapping mapping, ActionForm form, 
HttpServletRequest request, HttpServletResponse response) throws 
IOException, ServletException, UnknownSocietyException, SQLException

   {

   if(true)
return mapping.getInputForward();

   }
}

There is a "essai.html" in ./ and in ./usr/ (from my webapp of course) 
and that still does'nt work 
In case that help I use Struts 1.2.8, jdk1.4.2, Eclipse 3.1, linux 
(Mandriva 2006 Free)
I use the libraries i found in the struts-mailreader app in the struts 
1.2.8 zip file.

But i still have commons-digester.jar 1.5 because my app use rss object.

Thank


Rick Reumann a écrit :

There are several things you can do to test. Your blank page has me 
wondering if you are really even getting to where you 'think' you are. 
The first thing you need to figure out is if what you think is 
happening is really happening. Debugging Struts stuff can be a pain I 
know:)


I haven't seen your whole Action class, but put in some logging 
statements or use a debugger and make sure you are even getting here:


CandidateForm candidateForm = (CandidateForm) form;
   ActionMessages errors = candidateForm.validate();
   if (!errors.isEmpty()) {
   this.saveErrors(request, errors);
   return mapping.getInputForward();
   }

Then also print out the result of !errors.isEmpty. See if it's coming 
back false.


Then a few other things... Change your input page in your action 
mapping to some simple jsp that just has the text "hello"  on it. Skip 
your validation test above, but just try to return from your action 
with return mapping.getInputForward() and see if you get to your 
"hello" page.


Without access to your app it's difficult to debug. You might not even 
be executing the validation stuff above because of something else 
going on and maybe you are forwarding to your resulting page (and 
maybe that page doesn't exist?).


First step is using a debugger or print out some log statements.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Rick Reumann
There are several things you can do to test. Your blank page has me 
wondering if you are really even getting to where you 'think' you are. 
The first thing you need to figure out is if what you think is happening 
is really happening. Debugging Struts stuff can be a pain I know:)


I haven't seen your whole Action class, but put in some logging 
statements or use a debugger and make sure you are even getting here:


CandidateForm candidateForm = (CandidateForm) form;
   ActionMessages errors = candidateForm.validate();
   if (!errors.isEmpty()) {
   this.saveErrors(request, errors);
   return mapping.getInputForward();
   }

Then also print out the result of !errors.isEmpty. See if it's coming 
back false.


Then a few other things... Change your input page in your action mapping 
to some simple jsp that just has the text "hello"  on it. Skip your 
validation test above, but just try to return from your action with 
return mapping.getInputForward() and see if you get to your "hello" page.


Without access to your app it's difficult to debug. You might not even 
be executing the validation stuff above because of something else going 
on and maybe you are forwarding to your resulting page (and maybe that 
page doesn't exist?).


First step is using a debugger or print out some log statements.

--
Rick
http://www.learntechnology.net

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Thibaut
I use the libraries i found in the struts-mailreader app in the struts 
1.2.8 zip file.

But i still have commons-digester.jar 1.5 because my app use rss object ...

Can it be the problem ?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Thibaut

Rick Reumann a écrit :


Thibaut wrote the following on 3/22/2006 10:18 AM:


I did but it still doesn't work ... still have the blank page instead.



What do the error logs say?

In my /usr/java/jakarta-tomcat-5.0.28/logs/localhost_log.2006-03-22.txt 
there are just informations but no error ...

Where should i look for ?

Thank you for your help !

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Rick Reumann

Thibaut wrote the following on 3/22/2006 10:18 AM:

I did but it still doesn't work ... still have the blank page instead.


What do the error logs say?

--
Rick
http://www.learntechnology.net

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Mark Lowe
On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
> I did but it still doesn't work ... still have the blank page instead.
>
> Did i do something wrong with actionMessages and actionErrors ?
> Is it "" ?
> Is it "errors.add(ActionMessages.GLOBAL_MESSAGE, error);" ?

ActionErrors.GLOBAL_MESSAGE is inherited from ActionMessages..

saveErrors(..) should work fine..  should spit your errors out.

I'm stumped as well.. :(

Thinking about differences between 1.0 and 1.2 .. Have you defined you
resource bundle in struts-config rather than the servlet config?



would be the configuration if the resource bundle were to be called
messages.properties

to test this hypothesis you could try

ActionMessage error = new ActionMessage("Bad karma",false);

But i'd have thought that struts would just not find the message
rather than bailing silently..

But I'm only guessing ..

Mark

>
>
> Vinit Sharma a écrit :
>
> >If it is returning to a blank page then looks like your input is wrong.
> >Change input to:
> >input="/missions_copyMailToBasket.jsp"
> >
> >I believe this page is in the same dir as of close.jsp and mycv.jsp
> >
> >Thanks,
> >
> >
> >On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
> >
> >
> >>The problem is that if the validate(mapping,req) method return a not
> >>null errors object it goes on a blank page.
> >>None of the validations that work with Struts1.0 work with Struts1.2.8 ...
> >>I prefere to validate my form by putting the validate="true" in the
> >>struts-config.xml
> >>
> >>Thank you for your help !
> >>Thibaut
> >>
> >>Mark Lowe a écrit :
> >>
> >>
> >>
> >>>validate="true" just means that the validate(mapping,req) method will
> >>>be called and forwarded back to the inputForward before you get to the
> >>>action. But as you call it in the action this shouldn't matter..
> >>>
> >>>Are things going wrong in the validate method (i.e. does errors.size()
> >>>return zero even when its an invalid usecase) or is the problem
> >>>between saveErrors(..) and the jsp?
> >>>
> >>>Sorry I have no idea what's wrong either, but might help to know which
> >>>part isn't working..
> >>>
> >>>Mark
> >>>
> >>>On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
> >>>
> >>>
> >>>
> >>>
> Thank you for your quick reply !
> I really don't know what is the difference between what i do and the
> "struts-mailreader" exemple 
> 
> I already did what you write here. In fact it was the first think i did.
> I have this problem for *all my actions* in my app.
> 
> So the code is :
> 
> 
> 
> type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
>   input="missions_copyMailToBasket.jsp"
>   name="candidateForm"
>   scope="request"
>   validate="true">
>   
>   
>    
> ...
>  
>   parameter="com.cvdunet.controller.ApplicationResources"/>
> 
> 
> In the bean :
> 
> public ActionErrors validate(ActionMapping mapping,
> HttpServletRequest request)
> {
> ActionErrors errors  = new ActionErrors();
> ActionMessage error = new
> ActionMessage("com.cvdunet.response.NOBASKETSELECTED");
> errors.add(ActionMessages.GLOBAL_MESSAGE, error);
>  return errors;
>    }
> 
> 
> In the ApplicationResources.properties
> 
> com.cvdunet.response.NOBASKETSELECTED = No basket selected
> 
> 
> In the missions_copyMailToBasket.jsp :
> 
> ...
> 
> ...
> 
> 
> 
> 
> [EMAIL PROTECTED] a écrit :
> 
> 
> 
> 
> 
> >Hi
> >
> >Howecome you have validate="false"? If you want validation, then set it
> >
> >
> >>to true
> >>
> >>
> >-Original Message-
> >
> >
> >Hi
> >
> >I have all the time the same problem and there is a week i try to solve
> >it. It should be trivial but i can't see.
> >None of my validation work !
> >I now use Struts 1.2.8 with module. The application use to work with
> >Struts 1.0.
> >
> >In the Struts-config.xml of the "user" module :
> >
> >   >
> >type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
> > input="missions_copyMailToBasket.jsp"
> > name="candidateForm"
> > scope="request"
> > validate="false">
> > 
> > 
> >  
> >...
> >
> >
> > >parameter="com.cvdunet.controller.ApplicationResources"/>
> >
> >
> >
> >In the action :
> >
> >  CandidateForm candidateForm = (CandidateForm) form;
> >  ActionMessages errors = candidateForm.validate();
> >  if (!errors.isEmpty()) {
> >  this.saveErrors(request, errors);
> >  return mapping.getInputForward();
> >  }
> >
> >
> >
> >And in the fo

Re: Validation Problem

2006-03-22 Thread Thibaut

I did but it still doesn't work ... still have the blank page instead.

Did i do something wrong with actionMessages and actionErrors ?
Is it "" ?
Is it "errors.add(ActionMessages.GLOBAL_MESSAGE, error);" ?


Vinit Sharma a écrit :


If it is returning to a blank page then looks like your input is wrong.
Change input to:
input="/missions_copyMailToBasket.jsp"

I believe this page is in the same dir as of close.jsp and mycv.jsp

Thanks,


On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
 


The problem is that if the validate(mapping,req) method return a not
null errors object it goes on a blank page.
None of the validations that work with Struts1.0 work with Struts1.2.8 ...
I prefere to validate my form by putting the validate="true" in the
struts-config.xml

Thank you for your help !
Thibaut

Mark Lowe a écrit :

   


validate="true" just means that the validate(mapping,req) method will
be called and forwarded back to the inputForward before you get to the
action. But as you call it in the action this shouldn't matter..

Are things going wrong in the validate method (i.e. does errors.size()
return zero even when its an invalid usecase) or is the problem
between saveErrors(..) and the jsp?

Sorry I have no idea what's wrong either, but might help to know which
part isn't working..

Mark

On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:


 


Thank you for your quick reply !
I really don't know what is the difference between what i do and the
"struts-mailreader" exemple 

I already did what you write here. In fact it was the first think i did.
I have this problem for *all my actions* in my app.

So the code is :


  
 
 
  
...




In the bean :

   public ActionErrors validate(ActionMapping mapping,
HttpServletRequest request)
   {
   ActionErrors errors  = new ActionErrors();
   ActionMessage error = new
ActionMessage("com.cvdunet.response.NOBASKETSELECTED");
   errors.add(ActionMessages.GLOBAL_MESSAGE, error);
return errors;
  }


In the ApplicationResources.properties

com.cvdunet.response.NOBASKETSELECTED = No basket selected


In the missions_copyMailToBasket.jsp :

...

...




[EMAIL PROTECTED] a écrit :



   


Hi

Howecome you have validate="false"? If you want validation, then set it
 


to true
   


-Original Message-


Hi

I have all the time the same problem and there is a week i try to solve
it. It should be trivial but i can't see.
None of my validation work !
I now use Struts 1.2.8 with module. The application use to work with
Struts 1.0.

In the Struts-config.xml of the "user" module :

 


 
...






In the action :

 CandidateForm candidateForm = (CandidateForm) form;
 ActionMessages errors = candidateForm.validate();
 if (!errors.isEmpty()) {
 this.saveErrors(request, errors);
 return mapping.getInputForward();
 }



And in the form :

  public ActionMessages validate()
  {
  ActionMessages errors  = new ActionMessages();
  ActionMessage error = new
ActionMessage(CandidateConstant.NO_BASKET);
  errors.add(ActionMessages.GLOBAL_MESSAGE, error);
  return errors;
 }


Can anyone help ?
Thank you

--
Thibaut Lassalle

 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Vinit Sharma
If it is returning to a blank page then looks like your input is wrong.
Change input to:
input="/missions_copyMailToBasket.jsp"

I believe this page is in the same dir as of close.jsp and mycv.jsp

Thanks,


On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
>
> The problem is that if the validate(mapping,req) method return a not
> null errors object it goes on a blank page.
> None of the validations that work with Struts1.0 work with Struts1.2.8 ...
> I prefere to validate my form by putting the validate="true" in the
> struts-config.xml
>
> Thank you for your help !
> Thibaut
>
> Mark Lowe a écrit :
>
> >validate="true" just means that the validate(mapping,req) method will
> >be called and forwarded back to the inputForward before you get to the
> >action. But as you call it in the action this shouldn't matter..
> >
> >Are things going wrong in the validate method (i.e. does errors.size()
> >return zero even when its an invalid usecase) or is the problem
> >between saveErrors(..) and the jsp?
> >
> >Sorry I have no idea what's wrong either, but might help to know which
> >part isn't working..
> >
> >Mark
> >
> >On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
> >
> >
> >>Thank you for your quick reply !
> >>I really don't know what is the difference between what i do and the
> >>"struts-mailreader" exemple 
> >>
> >>I already did what you write here. In fact it was the first think i did.
> >>I have this problem for *all my actions* in my app.
> >>
> >>So the code is :
> >>
> >>
> >> >>
> >>type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
> >>   input="missions_copyMailToBasket.jsp"
> >>   name="candidateForm"
> >>   scope="request"
> >>   validate="true">
> >>   
> >>   
> >>
> >>...
> >>  
> >>   >>parameter="com.cvdunet.controller.ApplicationResources"/>
> >>
> >>
> >>In the bean :
> >>
> >> public ActionErrors validate(ActionMapping mapping,
> >>HttpServletRequest request)
> >> {
> >> ActionErrors errors  = new ActionErrors();
> >> ActionMessage error = new
> >>ActionMessage("com.cvdunet.response.NOBASKETSELECTED");
> >> errors.add(ActionMessages.GLOBAL_MESSAGE, error);
> >>  return errors;
> >>}
> >>
> >>
> >>In the ApplicationResources.properties
> >>
> >>com.cvdunet.response.NOBASKETSELECTED = No basket selected
> >>
> >>
> >>In the missions_copyMailToBasket.jsp :
> >>
> >>...
> >>
> >>...
> >>
> >>
> >>
> >>
> >>[EMAIL PROTECTED] a écrit :
> >>
> >>
> >>
> >>>Hi
> >>>
> >>>Howecome you have validate="false"? If you want validation, then set it
> to true
> >>>
> >>>
> >>>-Original Message-
> >>>
> >>>
> >>>Hi
> >>>
> >>>I have all the time the same problem and there is a week i try to solve
> >>>it. It should be trivial but i can't see.
> >>>None of my validation work !
> >>>I now use Struts 1.2.8 with module. The application use to work with
> >>>Struts 1.0.
> >>>
> >>>In the Struts-config.xml of the "user" module :
> >>>
> >>>>>>
> >>>type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
> >>>  input="missions_copyMailToBasket.jsp"
> >>>  name="candidateForm"
> >>>  scope="request"
> >>>  validate="false">
> >>>  
> >>>  
> >>>   
> >>>...
> >>>
> >>> 
> >>>  >>>parameter="com.cvdunet.controller.ApplicationResources"/>
> >>>
> >>>
> >>>
> >>>In the action :
> >>>
> >>>   CandidateForm candidateForm = (CandidateForm) form;
> >>>   ActionMessages errors = candidateForm.validate();
> >>>   if (!errors.isEmpty()) {
> >>>   this.saveErrors(request, errors);
> >>>   return mapping.getInputForward();
> >>>   }
> >>>
> >>>
> >>>
> >>>And in the form :
> >>>
> >>>public ActionMessages validate()
> >>>{
> >>>ActionMessages errors  = new ActionMessages();
> >>>ActionMessage error = new
> >>>ActionMessage(CandidateConstant.NO_BASKET);
> >>>errors.add(ActionMessages.GLOBAL_MESSAGE, error);
> >>>return errors;
> >>>   }
> >>>
> >>>
> >>>Can anyone help ?
> >>>Thank you
> >>>
> >>>--
> >>>Thibaut Lassalle
> >>>
> >>>
> >>>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
Vinit Sharma


Re: Validation Problem

2006-03-22 Thread Thibaut
The problem is that if the validate(mapping,req) method return a not 
null errors object it goes on a blank page.

None of the validations that work with Struts1.0 work with Struts1.2.8 ...
I prefere to validate my form by putting the validate="true" in the 
struts-config.xml


Thank you for your help !
Thibaut

Mark Lowe a écrit :


validate="true" just means that the validate(mapping,req) method will
be called and forwarded back to the inputForward before you get to the
action. But as you call it in the action this shouldn't matter..

Are things going wrong in the validate method (i.e. does errors.size()
return zero even when its an invalid usecase) or is the problem
between saveErrors(..) and the jsp?

Sorry I have no idea what's wrong either, but might help to know which
part isn't working..

Mark

On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
 


Thank you for your quick reply !
I really don't know what is the difference between what i do and the
"struts-mailreader" exemple 

I already did what you write here. In fact it was the first think i did.
I have this problem for *all my actions* in my app.

So the code is :


   
  
  
   
...
 
 


In the bean :

public ActionErrors validate(ActionMapping mapping,
HttpServletRequest request)
{
ActionErrors errors  = new ActionErrors();
ActionMessage error = new
ActionMessage("com.cvdunet.response.NOBASKETSELECTED");
errors.add(ActionMessages.GLOBAL_MESSAGE, error);
 return errors;
   }


In the ApplicationResources.properties

com.cvdunet.response.NOBASKETSELECTED = No basket selected


In the missions_copyMailToBasket.jsp :

...

...




[EMAIL PROTECTED] a écrit :

   


Hi

Howecome you have validate="false"? If you want validation, then set it to true


-Original Message-


Hi

I have all the time the same problem and there is a week i try to solve
it. It should be trivial but i can't see.
None of my validation work !
I now use Struts 1.2.8 with module. The application use to work with
Struts 1.0.

In the Struts-config.xml of the "user" module :

  
 
 
  
...






In the action :

  CandidateForm candidateForm = (CandidateForm) form;
  ActionMessages errors = candidateForm.validate();
  if (!errors.isEmpty()) {
  this.saveErrors(request, errors);
  return mapping.getInputForward();
  }



And in the form :

   public ActionMessages validate()
   {
   ActionMessages errors  = new ActionMessages();
   ActionMessage error = new
ActionMessage(CandidateConstant.NO_BASKET);
   errors.add(ActionMessages.GLOBAL_MESSAGE, error);
   return errors;
  }


Can anyone help ?
Thank you

--
Thibaut Lassalle

 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem

2006-03-22 Thread Mark Lowe
validate="true" just means that the validate(mapping,req) method will
be called and forwarded back to the inputForward before you get to the
action. But as you call it in the action this shouldn't matter..

Are things going wrong in the validate method (i.e. does errors.size()
return zero even when its an invalid usecase) or is the problem
between saveErrors(..) and the jsp?

Sorry I have no idea what's wrong either, but might help to know which
part isn't working..

Mark

On 3/22/06, Thibaut <[EMAIL PROTECTED]> wrote:
> Thank you for your quick reply !
> I really don't know what is the difference between what i do and the
> "struts-mailreader" exemple 
>
> I already did what you write here. In fact it was the first think i did.
> I have this problem for *all my actions* in my app.
>
> So the code is :
>
>
> 
> type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
>input="missions_copyMailToBasket.jsp"
>name="candidateForm"
>scope="request"
>validate="true">
>
>
> 
> ...
>   
>parameter="com.cvdunet.controller.ApplicationResources"/>
>
>
> In the bean :
>
>  public ActionErrors validate(ActionMapping mapping,
> HttpServletRequest request)
>  {
>  ActionErrors errors  = new ActionErrors();
>  ActionMessage error = new
> ActionMessage("com.cvdunet.response.NOBASKETSELECTED");
>  errors.add(ActionMessages.GLOBAL_MESSAGE, error);
>   return errors;
> }
>
>
> In the ApplicationResources.properties
>
> com.cvdunet.response.NOBASKETSELECTED = No basket selected
>
>
> In the missions_copyMailToBasket.jsp :
>
> ...
> 
> ...
>
>
>
>
>
>
> What's wrong ?
>
>
>
> [EMAIL PROTECTED] a écrit :
>
> >Hi
> >
> >Howecome you have validate="false"? If you want validation, then set it to 
> >true
> >
> >
> >-Original Message-
> >From: Thibaut [mailto:[EMAIL PROTECTED]
> >Sent: Wednesday, March 22, 2006 11:41 AM
> >To: [email protected]
> >Subject: Validation Problem
> >
> >
> >Hi
> >
> >I have all the time the same problem and there is a week i try to solve
> >it. It should be trivial but i can't see.
> >None of my validation work !
> >I now use Struts 1.2.8 with module. The application use to work with
> >Struts 1.0.
> >
> >In the Struts-config.xml of the "user" module :
> >
> > >
> >type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"
> >   input="missions_copyMailToBasket.jsp"
> >   name="candidateForm"
> >   scope="request"
> >   validate="false">
> >   
> >   
> >
> >...
> >
> >  
> >   >parameter="com.cvdunet.controller.ApplicationResources"/>
> >
> >
> >
> >In the action :
> >
> >CandidateForm candidateForm = (CandidateForm) form;
> >ActionMessages errors = candidateForm.validate();
> >if (!errors.isEmpty()) {
> >this.saveErrors(request, errors);
> >return mapping.getInputForward();
> >}
> >
> >
> >
> >And in the form :
> >
> > public ActionMessages validate()
> > {
> > ActionMessages errors  = new ActionMessages();
> > ActionMessage error = new
> >ActionMessage(CandidateConstant.NO_BASKET);
> > errors.add(ActionMessages.GLOBAL_MESSAGE, error);
> > return errors;
> >}
> >
> >
> >Can anyone help ?
> >Thank you
> >
> >--
> >Thibaut Lassalle
> >
> >
> >
>
> -
> 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: Validation Problem

2006-03-22 Thread Thibaut

Thank you for your quick reply !
I really don't know what is the difference between what i do and the 
"struts-mailreader" exemple 


I already did what you write here. In fact it was the first think i did. 
I have this problem for *all my actions* in my app.


So the code is :


 
type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"

  input="missions_copyMailToBasket.jsp"
  name="candidateForm"
  scope="request"
  validate="true">
  
  
   
...
 
 parameter="com.cvdunet.controller.ApplicationResources"/>



In the bean :

public ActionErrors validate(ActionMapping mapping, 
HttpServletRequest request)

{
ActionErrors errors  = new ActionErrors();
ActionMessage error = new 
ActionMessage("com.cvdunet.response.NOBASKETSELECTED");

errors.add(ActionMessages.GLOBAL_MESSAGE, error);
 return errors;
   }


In the ApplicationResources.properties

com.cvdunet.response.NOBASKETSELECTED = No basket selected


In the missions_copyMailToBasket.jsp :

...

...






What's wrong ?



[EMAIL PROTECTED] a écrit :


Hi

Howecome you have validate="false"? If you want validation, then set it to true


-Original Message-
From: Thibaut [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 22, 2006 11:41 AM
To: [email protected]
Subject: Validation Problem


Hi

I have all the time the same problem and there is a week i try to solve 
it. It should be trivial but i can't see.

None of my validation work !
I now use Struts 1.2.8 with module. The application use to work with 
Struts 1.0.


In the Struts-config.xml of the "user" module :

 
type="com.cvdunet.controller.action.UpdateResponsesForRequestAction"

  input="missions_copyMailToBasket.jsp"
  name="candidateForm"
  scope="request"
  validate="false">
  
  
   
...

 
 parameter="com.cvdunet.controller.ApplicationResources"/>




In the action :

   CandidateForm candidateForm = (CandidateForm) form;
   ActionMessages errors = candidateForm.validate();
   if (!errors.isEmpty()) {
   this.saveErrors(request, errors);
   return mapping.getInputForward();
   }



And in the form :

public ActionMessages validate()
{
ActionMessages errors  = new ActionMessages();
ActionMessage error = new 
ActionMessage(CandidateConstant.NO_BASKET);

errors.add(ActionMessages.GLOBAL_MESSAGE, error);
return errors;
   }


Can anyone help ?
Thank you

--
Thibaut Lassalle

 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Validation Problem

2006-03-22 Thread hermod.opstvedt
Hi

Howecome you have validate="false"? If you want validation, then set it to true

Hermod

-Original Message-
From: Thibaut [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 22, 2006 11:41 AM
To: [email protected]
Subject: Validation Problem


Hi

I have all the time the same problem and there is a week i try to solve 
it. It should be trivial but i can't see.
None of my validation work !
I now use Struts 1.2.8 with module. The application use to work with 
Struts 1.0.

In the Struts-config.xml of the "user" module :


   
   

...

  
  



In the action :

CandidateForm candidateForm = (CandidateForm) form;
ActionMessages errors = candidateForm.validate();
if (!errors.isEmpty()) {
this.saveErrors(request, errors);
return mapping.getInputForward();
}



And in the form :

 public ActionMessages validate()
 {
 ActionMessages errors  = new ActionMessages();
 ActionMessage error = new 
ActionMessage(CandidateConstant.NO_BASKET);
 errors.add(ActionMessages.GLOBAL_MESSAGE, error);
 return errors;
}


Can anyone help ?
Thank you

--
Thibaut Lassalle

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

This email with attachments is solely for the use of the individual or
entity to whom it is addressed. Please also be aware that the DnB NOR Group
cannot accept any payment orders or other legally binding correspondence with
customers as a part of an email. 

This email message has been virus checked by the virus programs used
in the DnB NOR Group.

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem - very urgent please reply

2006-01-10 Thread Raghu Kanchustambham
The trick is to point the "input" variable in your struts-config.xml to the
action class that "generated" the JSP page rather than the JSP page itself.

 

On failure of validation, you should redirect it to the "preparation" action
class for the form that solicits information for you - the action class
where you would be populating the "arraylist" that you are using in the JSP.

HTH,
~raghu~


On 1/10/06, Sony Thomas <[EMAIL PROTECTED]> wrote:
>
> Dear friends,
>
> I have a Add user jsp page and in my jsp page the user can select his
> language from a dropdown menu. I am generating it from the ArrayList
> property in UserForm.
>
>
> tabindex="8">
> property="languages" label="name" value="code"/>
>
>
>
> My problem is ,  when there is a validation error and control returns to
> the jsp page it is not able to find the languages collection, ie
> ArrayList. I know it is possible to solve by setting the form to
> session. but I dont want it to be in the session. Is there is any way
> out for this problem ??
>
> Please reply to me
>
> thanks in advance
>
>
> Sony
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Validation Problem - very urgent please reply

2006-01-10 Thread Vishal Gaurav
Hi,

I feel that the approach given by Peter would be fine.

You might be populating the drop down by iterating a collection fetched from
Database. When you submit the form only the selected value is submitted from
the drop down not the entire collection (That is why you do not get the
collection back on page load after validation failure).

Ideal workaround is to iterate the entire collection again within the JSP
and submit the same as hidden.

If your collection is of some object having attributes like id and value
then you need to submit two separate collections one for each type of
attribute.

In this case you need to ensure that in your form bean if there is a
validation error you need to map the hidden collection back into the form
just the way you do it while loading the page from the action class. You
will need to iterate through both the collections and remake the collection
of objects from the same and set it into the appropriate form property.

Please let me know if you need any further information.

Regards,
Vishal

On 1/10/06, Meenakshi Singh <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I would suggest that manually call validate and use Request Scope
> Not many people seem to be using this approach, yet I have found it to be
> the best overall solution.
>
> This is how it works:
> First of all make sure you do not have validate="true" set in your action
> mapping.You should call form.validate(..) manually.
>
> Then create a method to set up your request with any lists in scope. For
> example if you are using a DispatchAction you can simply have a private
> setUp(..) method in this Action. If you are creating separate Action
> classes
> for all of your different actions you might want to make this a separate
> class, or put it in a base Action class that your Actions can extend from.
> Now manually call your form's validate method, and then, based on whether
> ActionErrors return or not, you can decide what to do. If ActionErrors
> returns null/empty then validation was successful and you can continue
> your
> processing and forward on to success. If ActionErrors is not null/not
> empty,
> you have validation errors and need to call the setUp method to repopulate
> any lists then forward back to the JSP form.
>
> I am pasting a sample code from an article from a website to implement the
> above.
> You can look at this sample code & then try to implement it at your end.
>
>
> //class EmployeeDispatchAction
>
> private void setUp( HttpServletRequest request ) {
> Collection jobCodes = Service.getJobCodes();
> request.setAttribute("jobCodes", jobCodes);
> }
>
> public ActionForward setUpForm(ActionMapping mapping, ...) throws
> Exception {
> setUp( request );
> return (mapping.findForward(UIconstants.TO_FORM));
> }
>
> public ActionForward update(ActionMapping mapping, ...) throws
> Exception
> {
> ActionErrors errors = form.validate( mapping, request );
> if ( errors != null && !errors.isEmpty ) {
> saveErrors(request, errors);
> setUp(request);
> return (mapping.findForward(UIconstants.VALIDATION_FAILURE));
> }
> //Everything OK, continue on...
> return (mapping.findForward(UIconstants.SUCCESS));
> }
>
>
> Give it a try!!!
>
> Thanks & Regards,
> Meenakshi.
>
> PS: Let me know whether it worked for you or not.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


RE: Validation Problem - very urgent please reply

2006-01-10 Thread Meenakshi Singh
Hi,

I would suggest that manually call validate and use Request Scope
Not many people seem to be using this approach, yet I have found it to be
the best overall solution.

This is how it works:
First of all make sure you do not have validate=”true” set in your action
mapping.You should call form.validate(..) manually.

Then create a method to set up your request with any lists in scope. For
example if you are using a DispatchAction you can simply have a private
setUp(..) method in this Action. If you are creating separate Action classes
for all of your different actions you might want to make this a separate
class, or put it in a base Action class that your Actions can extend from.
Now manually call your form’s validate method, and then, based on whether
ActionErrors return or not, you can decide what to do. If ActionErrors
returns null/empty then validation was successful and you can continue your
processing and forward on to success. If ActionErrors is not null/not empty,
you have validation errors and need to call the setUp method to repopulate
any lists then forward back to the JSP form.

I am pasting a sample code from an article from a website to implement the
above.
You can look at this sample code & then try to implement it at your end.


//class EmployeeDispatchAction

private void setUp( HttpServletRequest request ) {
Collection jobCodes = Service.getJobCodes();
request.setAttribute(“jobCodes”, jobCodes);
}

public ActionForward setUpForm(ActionMapping mapping, ...) throws
Exception {
setUp( request );
return (mapping.findForward(UIconstants.TO_FORM));
}

public ActionForward update(ActionMapping mapping, ...) throws Exception
{
ActionErrors errors = form.validate( mapping, request );
if ( errors != null && !errors.isEmpty ) {
saveErrors(request, errors);
setUp(request);
return (mapping.findForward(UIconstants.VALIDATION_FAILURE));
}
//Everything OK, continue on...
return (mapping.findForward(UIconstants.SUCCESS));
}


Give it a try!!!

Thanks & Regards,
Meenakshi.

PS: Let me know whether it worked for you or not.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Validation Problem - very urgent please reply

2006-01-10 Thread Peter . Zoche
I had the same problem, and besides setting the form to session scope
you could do the following: Instead of storing your list of languages in
an ArrayList, store them in an array of Strings. Then on your jsp you
should be able to iterate over this list and sent all languages via the
html:hidden tag (that is why you have to use Strings, because they are sent
as Strings) with your request. So the languages are stored in your form with
every request, and when validation fails, you still have the languages
there.
The iteration should look something like this:





Hope that helps, perhaps you could reply when it works!

Peter

-Ursprüngliche Nachricht-
Von: Sony Thomas [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 10. Januar 2006 10:51
An: [email protected]
Betreff: Validation Problem - very urgent please reply


Dear friends,

I have a Add user jsp page and in my jsp page the user can select his 
language from a dropdown menu. I am generating it from the ArrayList 
property in UserForm.







My problem is ,  when there is a validation error and control returns to 
the jsp page it is not able to find the languages collection, ie 
ArrayList. I know it is possible to solve by setting the form to 
session. but I dont want it to be in the session. Is there is any way 
out for this problem ??

Please reply to me

thanks in advance


Sony

-
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: Validation problem

2005-07-12 Thread Rick Reumann

Rafael Taboada wrote the following on 7/11/2005 6:28 PM:

Thanks, I got it!...
 I needed to save the errors :)
 Rick Thanks for ur advice about using another class to manage JDBC... I'll 
review that... Do u know any samples about how to do that?..


Well typically I like to use the container managed connection pool. (If 
using Tomcat they have pretty simple docs on it.) The point is though to 
simply move that to another class. At the very least you'll want one 
other layer (typically a DAO layer) that takes care of doing your CRUD - 
-create,remove,update,delete stuff. This DAO layer is where you'd do the 
DB/JDBC stuff or if using something more slick like iBATIS/hibernate 
those call would do there also. So for an example updating an Employee


//In Action method:
execute(...) //or dispatchMethod update(..) {
  //cast to your ActionForm of String properties
  EmployeeActionForm eForm = (EmployeeActionForm)form;

  //business POJO with correct Data types
  EmployeeVO emp = new EmployeeVO();

  //easy to take the stuff from ActionForm to VO
  BeanUtils.copyProperties( emp, eForm );

  //Do the update
  yourEmployeeDAO.updateEmployee( emp );
}

I typically have one more layer before the dao, that I usually call a 
Service or Delegate (not using correct Design pattern terms I'm sure:) 
But anyway this way you can do several other business logic things and 
it even hides the dao part. So for example maybe besides doing an update 
to the DB you also needed to call an API to send out some e-mail 
notifications. This stuff I'd do in the service class...


//YourService
updateEmployee( EmployeeVO emp ) {
  //do the update
  yourDAO.updateEmployee( emp );
  //do some stuff or maybe some logic
  //like send out an email
}

//IN your Action it just changes from calling DAO to calling service
yourService.updateEmployee( emp );

If you take the above approach you'll keep your Actions pretty clean and 
easy to read and understand. Of course you might do some other stuff not 
shown the Action above like saving success messages, calling validation, 
saving some errors, some slight forwarding logic, etc. Point is to keep 
them clean though. If you aren't careful you'll end up with your Action 
classes doing too much business oriented tasks that can be better pushed 
off to another class.


--
Rick

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2005-07-12 Thread Borislav Sabev

Rafael Taboada wrote:


Hi folks, I'm doing my validation for my form fields...
I use validation framework, so I don't use validate method in my form bean.
The problem I have is the validate is called when I use for first time the 
module. I mean, when I see for frst ime the HTML form, validation is 
called... Why???
When I set validate attribute to false in my action mapping, validation is 
not called...

I want the validation is called only when the user click on submit button.
Did u have the same problem???
My Action extend DispatchAction class.
Thanks in advance.

 

Use 2 actions - one that shows the form and one that submit it, and 
validate the form ONLY on the second action (set the "validate" 
attribute in struts-config.xml to false or true respectively) This is a 
very common pattern in Struts.
If you use a DispatchAction (or derived from) to show and submit the 
form, than you have 2 choices:
1. the suggested upper (add just a smal forward action when you want to 
show the form)
2. recognize which "method" of the action (view or submit) is called - 
you can find it in the reuest, passed to validate() - and then make the 
validation only in case of submit.


Regards
Borislav


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: Validation problem

2005-07-12 Thread Borislav Sabev

Rick Reumann wrote:



if ( errors != null && !errors.isEmpty ) <-- this part can probably be 
shortened, I was too lazy to figure out what really gets returned if 
validation passes.. a null or empty ActionErrors?




here is part of the code of RequestProcessor, so in both cases the form 
is considered valid

   ActionMessages errors = form.validate(mapping, request);
--->>>if ((errors == null) || errors.isEmpty()) {
   if (log.isTraceEnabled()) {
   log.trace("  No errors detected, accepting input");
   }
   return (true);
   }

Regards
Borislav

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: Validation problem

2005-07-11 Thread Rafael Taboada
Thanks, I got it!...
 I needed to save the errors :)
 Rick Thanks for ur advice about using another class to manage JDBC... I'll 
review that... Do u know any samples about how to do that?..
 Thanks again

-- 
Rafael Taboada
Software Engineer

Cell : +511-97753290

"No creo en el destino pues no me gusta tener la idea de controlar mi vida"


Re: Validation problem

2005-07-11 Thread Michael Jouravlev
On 7/11/05, Rafael Taboada <[EMAIL PROTECTED]> wrote:
> Hi. When I turned off validation yn mi struts-config.xml, validation isn't
> called. And when I turned off validation and call validate manually inside a
> method of my ActionClass, validation isn't called.
>  I calle validate method in:
>  public ActionForward buscarColor(ActionMapping mapping, ActionForm
> form,HttpServletRequest request, HttpServletResponse response) {
> ...
> colorForm.validate(mapping,request);
> ...
> }
>  Maybe I'm calling this validate method in an incorrect way??

Hmm... It should be called. Are you sure that your validate in the
form overrides validate(ActionMapping mapping,
javax.servlet.http.HttpServletRequest request) and not this one
ActionErrors validate(ActionMapping mapping,
javax.servlet.ServletRequest request) ?

Put some debug output into your validate method as well before and
after your call to colorForm.validate(mapping,request), maybe this one
is not called.

Michael.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2005-07-11 Thread Rick Reumann

Rafael Taboada wrote the following on 7/11/2005 5:55 PM:
Hi. When I turned off validation yn mi struts-config.xml, validation isn't 
called. And when I turned off validation and call validate manually inside a 
method of my ActionClass, validation isn't called.

 I calle validate method in:
 public ActionForward buscarColor(ActionMapping mapping, ActionForm 
form,HttpServletRequest request, HttpServletResponse response) {

...
colorForm.validate(mapping,request);
...
}
 Maybe I'm calling this validate method in an incorrect way??


Are you 'sure' it's not being called?
You need get the Errors back that are returned and put them in scope.

Here's an example from my code...

//in your Action ...

ActionErrors errors = colorForm.validate( mapping, request );
if ( errors != null && !errors.isEmpty ) {
   saveErrors(request, errors);
   setUp(request); //puts some things back in scope that I need
   return (mapping.findForward(UIconstants.FAILURE));
}
return (mapping.findForward(UIconstants.SUCCESS));


if ( errors != null && !errors.isEmpty ) <-- this part can probably be 
shortened, I was too lazy to figure out what really gets returned if 
validation passes.. a null or empty ActionErrors?


--
Rick

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2005-07-11 Thread Rafael Taboada
Hi. When I turned off validation yn mi struts-config.xml, validation isn't 
called. And when I turned off validation and call validate manually inside a 
method of my ActionClass, validation isn't called.
 I calle validate method in:
 public ActionForward buscarColor(ActionMapping mapping, ActionForm 
form,HttpServletRequest request, HttpServletResponse response) {
...
colorForm.validate(mapping,request);
...
}
 Maybe I'm calling this validate method in an incorrect way??
  


-- 
Rafael Taboada
Software Engineer

Cell : +511-97753290

"No creo en el destino pues no me gusta tener la idea de controlar mi vida"


Re: Validation problem

2005-07-11 Thread Rick Reumann

Rafael Taboada wrote the following on 7/11/2005 5:34 PM:

Michael, it didn't work..


What didn't work? You still got validation when it was set to false?

(Also just a side note, it's good practice to move all the JDBC 
Connection stuff to another class other than your Action. You might be 
intending to do that later, so not meaning to critique too soon.)



 My Action class is:
 public class ColorAction extends DispatchAction {
 public ActionForward buscarColor(ActionMapping mapping, ActionForm form, 
HttpServletRequest request, HttpServletResponse response)

throws Exception {
ColorForm colorForm = (ColorForm) form;
MySQLDAOFactory factory = new MySQLDAOFactory();
DataSource ds = getDataSource(request,Constantes.DATASOURCEKEY);
Connection conn = ds.getConnection();
Collection collResultado;

try {
ColorDAO colorDAO = factory.getColorDAO(conn);
colorForm.validate(mapping,request);
collResultado = colorDAO.findColorByDescripcion(
colorForm.getstrFiltroDescripcion());
}
finally {
conn.close();
}

colorForm.setlstResultado(collResultado);

return mapping.getInputForward();
}
 ... //There are other methods
}



  So, what is wrong
I tried to use ValidatorActionForm instead of ValidatorForm... And of course 
in my validator call my actionmapping like: "/Colores", 
"/Colores?method=buscarColor"... But it doesn't work too...

 How can I do???... THanks in advance...
 When I turned off validate attribute... It doesn't validate anything... I'm 
calling validate method in my action class but it doesn't work...


Where are you calling validate manually? I don't see you doing that in 
the Action class you provided.



--
Rick

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2005-07-11 Thread Rafael Taboada
Michael, it didn't work..
 My ActionMapping is:
 
 My ActionForm is:
 public class ColorForm extends ValidatorForm {
private String strFiltroDescripcion;
private List lstResultado;
private String idColor;
private String strDescripcion;
private String[] chkColores;
 ... // Each attribute has its getter and setter
}
 My Action class is:
 public class ColorAction extends DispatchAction {
 public ActionForward buscarColor(ActionMapping mapping, ActionForm form, 
HttpServletRequest request, HttpServletResponse response)
throws Exception {
ColorForm colorForm = (ColorForm) form;
MySQLDAOFactory factory = new MySQLDAOFactory();
DataSource ds = getDataSource(request,Constantes.DATASOURCEKEY);
Connection conn = ds.getConnection();
Collection collResultado;

try {
ColorDAO colorDAO = factory.getColorDAO(conn);
colorForm.validate(mapping,request);
collResultado = colorDAO.findColorByDescripcion(
colorForm.getstrFiltroDescripcion());
}
finally {
conn.close();
}

colorForm.setlstResultado(collResultado);

return mapping.getInputForward();
}
 ... //There are other methods
}
 My jsp is:
 





 






  then it has logic:iterate in order to show search result..
 And my validator is:
 




  So, what is wrong
I tried to use ValidatorActionForm instead of ValidatorForm... And of course 
in my validator call my actionmapping like: "/Colores", 
"/Colores?method=buscarColor"... But it doesn't work too...
 How can I do???... THanks in advance...
 When I turned off validate attribute... It doesn't validate anything... I'm 
calling validate method in my action class but it doesn't work...
 Qny suggestion???

-- 
Rafael Taboada
Software Engineer

Cell : +511-97753290

"No creo en el destino pues no me gusta tener la idea de controlar mi vida"


Re: Validation problem

2005-07-11 Thread erikweber
I usually map multiple actions to the same form. Some have validate = true (for 
example, doAdd), some have validate = false (for example, viewAdd). Slightly 
different URL distinguishes them.

Does that help?

Erik

-Original Message-
From: Rafael Taboada <[EMAIL PROTECTED]>
Sent: Jul 11, 2005 4:49 PM
To: Struts List 
Subject: Validation problem

Hi folks, I'm doing my validation for my form fields...
 I use validation framework, so I don't use validate method in my form bean.
 The problem I have is the validate is called when I use for first time the 
module. I mean, when I see for frst ime the HTML form, validation is 
called... Why???
 When I set validate attribute to false in my action mapping, validation is 
not called...
 I want the validation is called only when the user click on submit button.
 Did u have the same problem???
 My Action extend DispatchAction class.
 Thanks in advance.

-- 
Rafael Taboada
Software Engineer

Cell : +511-97753290

"No creo en el destino pues no me gusta tener la idea de controlar mi vida"


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2005-07-11 Thread Michael Jouravlev
Rafael, turn validation off and call form.validate() manually from
your event handler method.

Michael.

On 7/11/05, Rafael Taboada <[EMAIL PROTECTED]> wrote:
> Hi folks, I'm doing my validation for my form fields...
>  I use validation framework, so I don't use validate method in my form bean.
>  The problem I have is the validate is called when I use for first time the
> module. I mean, when I see for frst ime the HTML form, validation is
> called... Why???
>  When I set validate attribute to false in my action mapping, validation is
> not called...
>  I want the validation is called only when the user click on submit button.
>  Did u have the same problem???
>  My Action extend DispatchAction class.
>  Thanks in advance.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Validation Problem with depends=URL

2005-05-04 Thread Benedict, Paul C
I hope Validator 1.1.5 comes out soon then!

-Original Message-
From: Niall Pemberton [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 04, 2005 3:53 PM
To: Struts Users Mailing List
Subject: Re: Validation Problem with depends=URL


No, it needs to be fixed in Validator and Validator to be released first -
once Validator is released we can then change Struts to depend on the new
validator version and then ship it in a release.

Niall
- Original Message - 
From: "Benedict, Paul C" <[EMAIL PROTECTED]>
To: "'Struts Users Mailing List'" 
Sent: Wednesday, May 04, 2005 8:15 PM
Subject: RE: Validation Problem with depends=URL


Will this be in 1.2.7?

-Original Message-
From: Niall Pemberton [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 04, 2005 3:13 PM
To: Struts Users Mailing List
Subject: Re: Validation Problem with depends=URL


This is a bug in validator:

http://issues.apache.org/bugzilla/show_bug.cgi?id=30686

Niall

- Original Message - 
From: "Günther Wieser" <[EMAIL PROTECTED]>
Sent: Wednesday, May 04, 2005 7:46 PM


as franck is in my team, i can answer this question on behalf of franck.

i think there went something wrong with the formatting of his email, of
course he types in "http://www.myurl.com"; (yes, without the quotes), but
whatever we enter, we get a validation error that this is not a valid url.
as far as i've seen it, it doesn't matter which scheme we use, e.g. an ftp
url also fails. tested on two different machines, which are almost 1000km
away from each other, so no chance that the bad spirit of one machine
reaches the other one ;-)



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






--
Notice:  This e-mail message, together with any attachments, contains
information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New
Jersey, USA 08889), and/or its affiliates (which may be known outside the
United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as
Banyu) that may be confidential, proprietary copyrighted and/or legally
privileged. It is intended solely for the use of the individual or entity
named on this message.  If you are not the intended recipient, and have
received this message in error, please notify us immediately by reply e-mail
and then delete it from your system.

--

-
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]





--
Notice:  This e-mail message, together with any attachments, contains 
information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New 
Jersey, USA 08889), and/or its affiliates (which may be known outside the 
United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as 
Banyu) that may be confidential, proprietary copyrighted and/or legally 
privileged. It is intended solely for the use of the individual or entity named 
on this message.  If you are not the intended recipient, and have received this 
message in error, please notify us immediately by reply e-mail and then delete 
it from your system.
--

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem with depends=URL

2005-05-04 Thread Niall Pemberton
No, it needs to be fixed in Validator and Validator to be released first -
once Validator is released we can then change Struts to depend on the new
validator version and then ship it in a release.

Niall
- Original Message - 
From: "Benedict, Paul C" <[EMAIL PROTECTED]>
To: "'Struts Users Mailing List'" 
Sent: Wednesday, May 04, 2005 8:15 PM
Subject: RE: Validation Problem with depends=URL


Will this be in 1.2.7?

-Original Message-
From: Niall Pemberton [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 04, 2005 3:13 PM
To: Struts Users Mailing List
Subject: Re: Validation Problem with depends=URL


This is a bug in validator:

http://issues.apache.org/bugzilla/show_bug.cgi?id=30686

Niall

- Original Message - 
From: "Günther Wieser" <[EMAIL PROTECTED]>
Sent: Wednesday, May 04, 2005 7:46 PM


as franck is in my team, i can answer this question on behalf of franck.

i think there went something wrong with the formatting of his email, of
course he types in "http://www.myurl.com"; (yes, without the quotes), but
whatever we enter, we get a validation error that this is not a valid url.
as far as i've seen it, it doesn't matter which scheme we use, e.g. an ftp
url also fails. tested on two different machines, which are almost 1000km
away from each other, so no chance that the bad spirit of one machine
reaches the other one ;-)



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






--
Notice:  This e-mail message, together with any attachments, contains
information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New
Jersey, USA 08889), and/or its affiliates (which may be known outside the
United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as
Banyu) that may be confidential, proprietary copyrighted and/or legally
privileged. It is intended solely for the use of the individual or entity
named on this message.  If you are not the intended recipient, and have
received this message in error, please notify us immediately by reply e-mail
and then delete it from your system.

--

-
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: Validation Problem with depends=URL

2005-05-04 Thread Benedict, Paul C
Will this be in 1.2.7?

-Original Message-
From: Niall Pemberton [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 04, 2005 3:13 PM
To: Struts Users Mailing List
Subject: Re: Validation Problem with depends=URL


This is a bug in validator:

http://issues.apache.org/bugzilla/show_bug.cgi?id=30686

Niall

- Original Message - 
From: "Günther Wieser" <[EMAIL PROTECTED]>
Sent: Wednesday, May 04, 2005 7:46 PM


as franck is in my team, i can answer this question on behalf of franck.

i think there went something wrong with the formatting of his email, of
course he types in "http://www.myurl.com"; (yes, without the quotes), but
whatever we enter, we get a validation error that this is not a valid url.
as far as i've seen it, it doesn't matter which scheme we use, e.g. an ftp
url also fails. tested on two different machines, which are almost 1000km
away from each other, so no chance that the bad spirit of one machine
reaches the other one ;-)



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Notice:  This e-mail message, together with any attachments, contains 
information of Merck & Co., Inc. (One Merck Drive, Whitehouse Station, New 
Jersey, USA 08889), and/or its affiliates (which may be known outside the 
United States as Merck Frosst, Merck Sharp & Dohme or MSD and in Japan, as 
Banyu) that may be confidential, proprietary copyrighted and/or legally 
privileged. It is intended solely for the use of the individual or entity named 
on this message.  If you are not the intended recipient, and have received this 
message in error, please notify us immediately by reply e-mail and then delete 
it from your system.
--

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation Problem with depends=URL

2005-05-04 Thread Niall Pemberton
This is a bug in validator:

http://issues.apache.org/bugzilla/show_bug.cgi?id=30686

Niall

- Original Message - 
From: "Günther Wieser" <[EMAIL PROTECTED]>
Sent: Wednesday, May 04, 2005 7:46 PM


as franck is in my team, i can answer this question on behalf of franck.

i think there went something wrong with the formatting of his email, of
course he types in "http://www.myurl.com"; (yes, without the quotes), but
whatever we enter, we get a validation error that this is not a valid url.
as far as i've seen it, it doesn't matter which scheme we use, e.g. an ftp
url also fails. tested on two different machines, which are almost 1000km
away from each other, so no chance that the bad spirit of one machine
reaches the other one ;-)



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Validation Problem with depends=URL

2005-05-04 Thread =?iso-8859-1?Q?G=FCnther_Wieser?=
hi,

as franck is in my team, i can answer this question on behalf of franck.

i think there went something wrong with the formatting of his email, of
course he types in "http://www.myurl.com"; (yes, without the quotes), but
whatever we enter, we get a validation error that this is not a valid url.
as far as i've seen it, it doesn't matter which scheme we use, e.g. an ftp
url also fails. tested on two different machines, which are almost 1000km
away from each other, so no chance that the bad spirit of one machine
reaches the other one ;-)

kr,
guenther


--
Günther Wieser

creative-it
Guglgasse 6/1/11/1
A-1110 Wien
Austria
http://www.creative-it.com


-Original Message-
From: Dave Newton [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 04, 2005 4:35 PM
To: Struts Users Mailing List
Subject: Re: Validation Problem with depends=URL

Franck Wiegner wrote:

>invalid url I also get an error-msg, still okay. but when I enter a 
>valid url (example:  <http://www.myurl.com/> http://www.myurl.com) I 
>also get the message that this is an invalid url, which is not okay, 
>cause as long as I am not able to enter valid urls my form bean will never
parse.
>  
>
What happens if you just enter "http://www.myurl.com"; (without the quotes,
of course)?

Dave



-
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: Validation Problem with depends=URL

2005-05-04 Thread Dave Newton
Franck Wiegner wrote:
invalid url I also get an error-msg, still okay. but when I enter a valid
url (example:   http://www.myurl.com) I also get the
message that this is an invalid url, which is not okay, cause as long as I
am not able to enter valid urls my form bean will never parse.
 

What happens if you just enter "http://www.myurl.com"; (without the 
quotes, of course)?

Dave

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Validation problem - for a form with multiple names

2005-01-20 Thread Matt Bathje
Manisha Sathe wrote:
I have a form whose fields are from an dynamic customer array. I display Customer name and giving i/p field  for Amount to enter. 
 
The JSP might contain 2-3 text fields called amt against different customers (I am identifying it with IDs)
 
My form bean is something like this,
 
public class AddressForm extends ValidatorForm
//ActionForm
{
...
  private String[] amt;
 ...
 public String[] getAmt()
 {
  return this.amt;
 }
 public void setAmt(String[] amt)
 {
  this.amt = amt;
 }
 
...
}
 
I am using Validator, 
 
validation.xml is something like this
 

depends="required">




 
1) When validation fails and it comes back to jsp form -BUT  the bydefault values of Amount is something like : [Ljava.lang.String;@f2da21
 
I understand this is because i have declared it as an array. But how to get rid of this. 
 
2)I face a problem when i also want to validate as float. As i/p taken is amt[1], amt[2] ... it never gets validated as float where as i want to validate individual i/p text field as float.
 
How can i achieve it ?
 

Manisha - I think these messages in the archives are very similar to 
your problem.

http://www.mail-archive.com/[email protected]/msg18871.html
http://www.mail-archive.com/[email protected]/msg18895.html
http://www.mail-archive.com/[email protected]/msg18925.html
As well as this bug report:
http://issues.apache.org/bugzilla/show_bug.cgi?id=32978
Basically you can't validate each element of an array of String[] with 
the validator, because it does not have getters/setters for its value. 
Your choices are to use the validate method in the action form to do the 
validation, or to setup a new class with an amount property and 
getters/setters for the amounts, then use an array of that instead of 
String[]

Matt
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Validation problem - form still submits after client-side validation fails.

2004-09-21 Thread James Mitchell
You do not need to submit the form if you are using an input type="image".
That's what it does if it is pressed (unless the image is outside of the
... tags.  Make sure your html:form has the proper
onsubmit="return validateXYZForm()" (notice that 'return' will stop the page
from submitting if validation fails), just calling validateXYZForm() will
still allow the request to continue in most browsers.

(this will look a little different depending on which incarnation you are
using ValidatorForm/ValidatorActionForm (with or without Dyna) )


...
...






--
James Mitchell
Software Engineer / Open Source Evangelist
EdgeTech, Inc.
678.910.8017
AIM: jmitchtx

- Original Message -
From: <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Monday, September 20, 2004 5:42 PM
Subject: Re: Validation problem - form still submits after client-side
validat ion fails.


>
>
>
>
> If I'm understanding your scenario correctly your onclick needs to call a
> function that will call the submit() on the form only if the validation
> passes.
>
>
> "Barnett, Brian W." <[EMAIL PROTECTED]> wrote on 09/20/2004 04:51:55
> PM:
>
> > Both the client-side and the server-side validation are executing
instead
> of
> > just the client-side. I know it has something to do with the way I've
> coded
> > the save button. The underlying problem is that I want to use images and
> > roll-over images for the save button but I also want the "enter" key to
> > submit the form.
> >
> >
> >
> > Here is the save button code in the jsp:
> >
> >
> >
> >  >
>
onclick="document.forms[0].Dispatch.value='Save';document.forms[0].submit();
>
> > " src="/images/btn_primary_action_save.gif" align="right"
> > onmouseover="src='/images/btn_primary_action_save_roll.gif'"
> > onmouseout="src='/images/btn_primary_action_save.gif'"/>
> >
> >
> >
> > The roll-over images works, and the "enter" key works but it looks like
> the
> > form still gets submitted after client-side validation fails. Does
anyone
> > know how to prevent that and still maintain images and "enter" key
> > functionality?
> >
> >
> >
> > Thanks,
> >
> > Brian Barnett
> >
>
>
> -
> 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: Validation problem - form still submits after client-side validation fails.

2004-09-20 Thread David G. Friedman
Brian,

To answer your question:

> Both the client-side and the server-side validation
> are executing instead of just the client-side.

Set your action in struts-config.xml to validate="false".
Your html:javascript will still work for the client-side
validation but NOTHING will be done on the server end
once the form is submitted by the client's browser.

Regards,
David

-Original Message-
From: Barnett, Brian W. [mailto:[EMAIL PROTECTED]
Sent: Monday, September 20, 2004 4:52 PM
To: '[EMAIL PROTECTED]'
Subject: Validation problem - form still submits after client-side
validation fails.


Both the client-side and the server-side validation are executing instead of
just the client-side. I know it has something to do with the way I've coded
the save button. The underlying problem is that I want to use images and
roll-over images for the save button but I also want the "enter" key to
submit the form.



Here is the save button code in the jsp:







The roll-over images works, and the "enter" key works but it looks like the
form still gets submitted after client-side validation fails. Does anyone
know how to prevent that and still maintain images and "enter" key
functionality?



Thanks,

Brian Barnett



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem - form still submits after client-side validat ion fails.

2004-09-20 Thread Hubert Rabago
I could be wrong, and i don't have the time to verify this with code
right now, but it's possible that the reason the form still gets
submitted is because you're calling form.submit() directly.  That
might be bypassing the onsubmit="return validateMyForm(this)".  You
*do* have that, right?  I don't know how to do what you're trying to
do with image buttons, though.  For that, you'll probably want Mike
McGrady's opinion since he works with image buttons a lot.

Do you have to call submit() explicitly?

Hubert

On Mon, 20 Sep 2004 15:51:55 -0500, Barnett, Brian W.
<[EMAIL PROTECTED]> wrote:
> Both the client-side and the server-side validation are executing instead of
> just the client-side. I know it has something to do with the way I've coded
> the save button. The underlying problem is that I want to use images and
> roll-over images for the save button but I also want the "enter" key to
> submit the form.
> 
> Here is the save button code in the jsp:
> 
>  onclick="document.forms[0].Dispatch.value='Save';document.forms[0].submit();
> " src="/images/btn_primary_action_save.gif" align="right"
> onmouseover="src='/images/btn_primary_action_save_roll.gif'"
> onmouseout="src='/images/btn_primary_action_save.gif'"/>
> 
> The roll-over images works, and the "enter" key works but it looks like the
> form still gets submitted after client-side validation fails. Does anyone
> know how to prevent that and still maintain images and "enter" key
> functionality?
> 
> Thanks,
> 
> Brian Barnett
> 
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem - form still submits after client-side validat ion fails.

2004-09-20 Thread bmf5




If I'm understanding your scenario correctly your onclick needs to call a
function that will call the submit() on the form only if the validation
passes.


"Barnett, Brian W." <[EMAIL PROTECTED]> wrote on 09/20/2004 04:51:55
PM:

> Both the client-side and the server-side validation are executing instead
of
> just the client-side. I know it has something to do with the way I've
coded
> the save button. The underlying problem is that I want to use images and
> roll-over images for the save button but I also want the "enter" key to
> submit the form.
>
>
>
> Here is the save button code in the jsp:
>
>
>
> 
onclick="document.forms[0].Dispatch.value='Save';document.forms[0].submit();

> " src="/images/btn_primary_action_save.gif" align="right"
> onmouseover="src='/images/btn_primary_action_save_roll.gif'"
> onmouseout="src='/images/btn_primary_action_save.gif'"/>
>
>
>
> The roll-over images works, and the "enter" key works but it looks like
the
> form still gets submitted after client-side validation fails. Does anyone
> know how to prevent that and still maintain images and "enter" key
> functionality?
>
>
>
> Thanks,
>
> Brian Barnett
>


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Validation problem

2004-05-18 Thread None None
ARGH... I found my problem... simple typo in my message resouce file... the 
html:errors tag just wasn't finding the right key for one of my errors, and 
thus wasn't displaying anything, making it look like I was only gettiing 
one.  Sorry folks, false alarm :)


From: Iván Rodríguez <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Subject: Re: Validation problem
Date: Tue, 18 May 2004 17:43:16 +0200
Try:


  



- Original Message -
From: "None None" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 18, 2004 5:32 PM
Subject: Validation problem
> Hello again... I'm playing with validation for the first time, and I got
it
> almost working completely, one remaining problem...
>
> In my ActionForm validate() method, I am checking two elements for 
errors,
> In my test case, both should be getting flagged as incorrect (and they
are,
> I can see that both blocks of code are executing, so I am rather certain 
I
> have two ActionError objects being added to the ActionErrors collection
> being returned from validate()).
>
> The problem is, I'm only getting one of them displayed back to me.  
Here's
> what I'm doing in the JSP:
>
> 
> 
> 
>
> My understanding is that the html:errors tag should be iterating over 
the
> collection and displaying all the errors (even if not in a format I'd be
> happy with, that's the next problem).  Why am I only seeing the first 
one
> though?  What am I missing?  Thanks all!
>
> _
> MSN Toolbar provides one-click access to Hotmail from any Web page - 
FREE
> download! http://toolbar.msn.click-url.com/go/onm00200413ave/direct/01/
>
>
> -
> 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]
_
Get 200+ ad-free, high-fidelity stations and LIVE Major League Baseball 
Gameday Audio! http://radio.msn.click-url.com/go/onm00200491ave/direct/01/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Validation problem

2004-05-18 Thread None None
I came across that, but I'm getting the following error:
javax.servlet.ServletException: Cannot find bean error in any scope
Does the ActionErrors object get set as another name?  I'm using Struts 1.1, 
everything I'm reading seems to agree that it should be named "error"...

From: Iván Rodríguez <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Subject: Re: Validation problem
Date: Tue, 18 May 2004 17:43:16 +0200
Try:


  



- Original Message -
From: "None None" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 18, 2004 5:32 PM
Subject: Validation problem
> Hello again... I'm playing with validation for the first time, and I got
it
> almost working completely, one remaining problem...
>
> In my ActionForm validate() method, I am checking two elements for 
errors,
> In my test case, both should be getting flagged as incorrect (and they
are,
> I can see that both blocks of code are executing, so I am rather certain 
I
> have two ActionError objects being added to the ActionErrors collection
> being returned from validate()).
>
> The problem is, I'm only getting one of them displayed back to me.  
Here's
> what I'm doing in the JSP:
>
> 
> 
> 
>
> My understanding is that the html:errors tag should be iterating over 
the
> collection and displaying all the errors (even if not in a format I'd be
> happy with, that's the next problem).  Why am I only seeing the first 
one
> though?  What am I missing?  Thanks all!
>
> _
> MSN Toolbar provides one-click access to Hotmail from any Web page - 
FREE
> download! http://toolbar.msn.click-url.com/go/onm00200413ave/direct/01/
>
>
> -
> 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]
_
FREE pop-up blocking with the new MSN Toolbar – get it now! 
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Validation problem

2004-05-18 Thread Iván Rodríguez
Try:




  






- Original Message - 
From: "None None" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 18, 2004 5:32 PM
Subject: Validation problem


> Hello again... I'm playing with validation for the first time, and I got
it
> almost working completely, one remaining problem...
>
> In my ActionForm validate() method, I am checking two elements for errors,
> In my test case, both should be getting flagged as incorrect (and they
are,
> I can see that both blocks of code are executing, so I am rather certain I
> have two ActionError objects being added to the ActionErrors collection
> being returned from validate()).
>
> The problem is, I'm only getting one of them displayed back to me.  Here's
> what I'm doing in the JSP:
>
> 
> 
> 
>
> My understanding is that the html:errors tag should be iterating over the
> collection and displaying all the errors (even if not in a format I'd be
> happy with, that's the next problem).  Why am I only seeing the first one
> though?  What am I missing?  Thanks all!
>
> _
> MSN Toolbar provides one-click access to Hotmail from any Web page - FREE
> download! http://toolbar.msn.click-url.com/go/onm00200413ave/direct/01/
>
>
> -
> 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]