Re: about struts-examples apache/struts-examples -> bean-validation example

2015-09-03 Thread Chris
Hello, 

The bean-validation example works now, after adding jboss-logging-3.1.1.GA.jar

I didn't know I could use a jboss file jar with only Netbeans 7.3 and Apache 
Tomcat 7.0.34.So the java jar file influence the validation and the message 
errors directly on html page. 


PS : with the exclude_parameters example, the errors messages are not in the 
same files
===
exclude_parameters :
EditAction.properties
personBean.firstName=First name

EditAction-validation.xml

 
 personBean.firstName
 First name is required.
 

===

bean-validation ( All is in EditAction.properties ) 

EditAction.properties
personBean.firstName=First name
firstName.required=You must enter the first 
name===

Regards,

Chris




Re: about struts-examples apache/struts-examples -> bean-validation example

2015-09-03 Thread Christoph Nenning
> So the java jar file influence the 
> validation and the message errors directly on html page. 


When you don't specifiy own messages/text-keys in validation annotations 
the bean-validation framework uses default messages. In your case these 
messages should come from hibernate-validation.jar.


Here is an example from struts docs how you can use an own text-key:

@NotNull(message="your.text.key.here") 


http://struts.apache.org/docs/bean-validation-plugin.html



Regards,
Christoph




> From: Chris <christal...@yahoo.fr>
> To: Lukasz Lenart <lukaszlen...@apache.org>, 
> "user@struts.apache.org" <user@struts.apache.org>, Struts Users 
> Mailing List <user@struts.apache.org>, 
> Date: 03.09.2015 11:38
> Subject: Re: about struts-examples apache/struts-examples -> bean-
> validation example
> 
> Hello, 
> 
> The bean-validation example works now, after adding 
jboss-logging-3.1.1.GA.jar
> 
> I didn't know I could use a jboss file jar with only Netbeans 7.3 
> and Apache Tomcat 7.0.34.So the java jar file influence the 
> validation and the message errors directly on html page. 
> 
> 
> PS : with the exclude_parameters example, the errors messages are 
> not in the same files
> ===
> exclude_parameters :
> EditAction.properties
> personBean.firstName=First name
> 
> EditAction-validation.xml
> 
>  
>  personBean.firstName
>  First name is required.
>  
> 
> ===
> 
> bean-validation ( All is in EditAction.properties ) 
> 
> EditAction.properties
> personBean.firstName=First name
> firstName.required=You must enter the first 
> name===
> 
> Regards,
> 
> Chris
> 
> 

This Email was scanned by Sophos Anti Virus


Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Christoph Nenning
> It seems there are some new examples in apache/struts-examples

Yeah, having more examples is great, isn't it?



> bean-validation: It seems we need 2 jar 

Yes, as it is declared in poms.



Regards,
Christoph





> From: Chris <christal...@yahoo.fr>
> To: "user@struts.apache.org" <user@struts.apache.org>, 
> Date: 01.09.2015 19:53
> Subject: about struts-examples https://github.com/apache/struts-examples
> 
> Hello, 
> It seems there are some new examples in apache/struts-examplesFrom A
> to Z1 ) bean-validation2 ) blank3 ) jboss-blanc4 ) mailreader5 ) 
> restful2actionmapper6) themes_override
> About 
> 1 ) bean-validationIt seems we need 2 jar  ( validation-api-1.1.
> 0.Final.jar and hibernate ? ) 
> bean-validation.
> 1 ) org.apache.struts.edit.action.EditAction.java   needs ->  
> javax.validation.*( validation-api-1.1.0.Final.jar OK in package
> stuts2.5 BETA1 )
> 2 ) org.apache.struts.edit.model;Person;java
> needs ->  javax.validation.constraints.*( validation-api-1.1.
> 0.Final.jar ) OK
> AND  ->  
org.hibernate.validator.constraints.*
> What do you think ? 
> Regards
> chris
> 
> |   |
> |   |  |   |   |   |   |   |
> | apache/struts-examplesstruts-examples - Mirror of Apache Struts |
> |  |
> | Afficher sur github.com | Aperçu par Yahoo |
> |  |
> |   |
> 
> 

This Email was scanned by Sophos Anti Virus


Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Chris
Thank you, 
so I added the right 4.3.1.Final version but I also need app-validation.

 Then I noticed that even if the application starts, unfortunately the tests in 
the form are not controled. Everything happens as if there were no control !.
 See ... without parameters..Updated Information
Your information:
First Name:  |  Last Name:  |  Favorite Sport: basketball |  Gender: not sure | 
 Residency: KS |  Over 21: false |  Car models: [] |  Email:  |  Phone: 
Return to home page.
Extracts : 
2015-09-02 15:18:25,588 WARN  [http-bio-8080-exec-9] 
interceptor.DefaultBeanValidationManager (DefaultBeanValidationManager.java:80) 
- ** No bean validator class defined - Falling back to default provider 
**Extracts :2015-09-02 15:18:25,605 ERROR [http-bio-8080-exec-9] 
providers.InterceptorBuilder (InterceptorBuilder.java:75) - Unable to load 
config class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
com.opensymphony.xwork2.config.ConfigurationException: Caught Exception while 
registering Interceptor class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
    at 
com.opensymphony.xwork2.factory.DefaultInterceptorFactory.buildInterceptor(DefaultInterceptorFactory.java:69)
 ~[struts2-core-2.5-BETA1.jar:2.5-BETA1]
    at 
com.opensymphony.xwork2.ObjectFactory.buildInterceptor(ObjectFactory.java:198) 
~[struts2-core-2.5-BETA1.jar:2.5-BETA1]


2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (jakarta) for 
(org.apache.struts2.dispatcher.multipart.MultiPartRequest)
2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(org.apache.struts2.views.freemarker.FreemarkerManager)
2015-09-02 15:18:25,348 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.validator.ActionValidatorManager)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory)
2015-09-02 15:18:25,350 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionProvider)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionContextFactory)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.dispatcher.StaticContentLoader)
2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.UnknownHandlerManager)
2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.views.util.UrlHelper)
2015-09-02 15:18:25,353 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.TextParser)
2015-09-02 15:18:25,404 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(org.apache.struts2.dispatcher.DispatcherErrorHandler)
2015-09-02 15:18:25,404 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.security.ExcludedPatternsChecker)
2015-09-02 15:18:25,405 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.security.AcceptedPatternsChecker)
2015-09-02 15:18:25,588 WARN  [http-bio-8080-exec-9] 
interceptor.DefaultBeanValidationManager 

Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Lukasz Lenart
2015-09-01 19:50 GMT+02:00 Chris :
> Hello,
> It seems there are some new examples in apache/struts-examplesFrom A to Z1 ) 
> bean-validation2 ) blank3 ) jboss-blanc4 ) mailreader5 ) 
> restful2actionmapper6) themes_override

Yes

1) to show how to use the new Bean Validation Plugin
2-4) moved from Struts to reduce its weight
5) no idea :)
6) how to override theme's templates

> About
> 1 ) bean-validationIt seems we need 2 jar  ( validation-api-1.1.0.Final.jar 
> and hibernate ? )
> bean-validation.
> 1 ) org.apache.struts.edit.action.EditAction.java   needs ->  
> javax.validation.*( validation-api-1.1.0.Final.jar OK in package stuts2.5 
> BETA1 )
> 2 ) org.apache.struts.edit.model;Person;java
> needs ->  javax.validation.constraints.*( validation-api-1.1.0.Final.jar 
> ) OK
> AND  ->  org.hibernate.validator.constraints.*
> What do you think ?

It depends on what implementation of Bean Validation you use/prefer


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

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Lukasz Lenart
JBoss is using its own logging layer

http://stackoverflow.com/questions/12615566/java-noclassdeffound-error

2015-09-02 15:48 GMT+02:00 Chris :
> Thank you,
> so I added the right 4.3.1.Final version but I also need app-validation.
>
>  Then I noticed that even if the application starts, unfortunately the tests 
> in the form are not controled. Everything happens as if there were no control 
> !.
>  See ... without parameters..Updated Information
> Your information:
> First Name:  |  Last Name:  |  Favorite Sport: basketball |  Gender: not sure 
> |  Residency: KS |  Over 21: false |  Car models: [] |  Email:  |  Phone:
> Return to home page.
> Extracts :
> 2015-09-02 15:18:25,588 WARN  [http-bio-8080-exec-9] 
> interceptor.DefaultBeanValidationManager 
> (DefaultBeanValidationManager.java:80) - ** No bean validator class 
> defined - Falling back to default provider **Extracts :2015-09-02 
> 15:18:25,605 ERROR [http-bio-8080-exec-9] providers.InterceptorBuilder 
> (InterceptorBuilder.java:75) - Unable to load config class 
> org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
> com.opensymphony.xwork2.config.ConfigurationException: Caught Exception while 
> registering Interceptor class 
> org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
> at 
> com.opensymphony.xwork2.factory.DefaultInterceptorFactory.buildInterceptor(DefaultInterceptorFactory.java:69)
>  ~[struts2-core-2.5-BETA1.jar:2.5-BETA1]
> at 
> com.opensymphony.xwork2.ObjectFactory.buildInterceptor(ObjectFactory.java:198)
>  ~[struts2-core-2.5-BETA1.jar:2.5-BETA1]
>
>
> 2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (jakarta) for 
> (org.apache.struts2.dispatcher.multipart.MultiPartRequest)
> 2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (org.apache.struts2.views.freemarker.FreemarkerManager)
> 2015-09-02 15:18:25,348 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer)
> 2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (com.opensymphony.xwork2.validator.ActionValidatorManager)
> 2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory)
> 2015-09-02 15:18:25,350 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (com.opensymphony.xwork2.util.reflection.ReflectionProvider)
> 2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (com.opensymphony.xwork2.util.reflection.ReflectionContextFactory)
> 2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher)
> 2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher)
> 2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (org.apache.struts2.dispatcher.StaticContentLoader)
> 2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (com.opensymphony.xwork2.UnknownHandlerManager)
> 2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (org.apache.struts2.views.util.UrlHelper)
> 2015-09-02 15:18:25,353 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for (com.opensymphony.xwork2.util.TextParser)
> 2015-09-02 15:18:25,404 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (org.apache.struts2.dispatcher.DispatcherErrorHandler)
> 2015-09-02 15:18:25,404 INFO  [http-bio-8080-exec-9] 
> config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) 
> - Choosing bean (struts) for 
> (com.opensymphony.xwork2.security.ExcludedPatternsChecker)
> 2015-09-02 

Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Chris
I am using the files23/11/2013  17:55    43ÿ578 asm-3.3.jar
23/11/2013  17:55    38ÿ275 asm-commons-3.3.jar
23/11/2013  17:55    21ÿ503 asm-tree-3.3.jar
19/02/2014  16:21    69ÿ002 commons-fileupload-1.3.1.jar
04/04/2014  11:19   185ÿ140 commons-io-2.4.jar
10/06/2015  07:51   434ÿ678 commons-lang3-3.4.jar
03/04/2015  07:09 1ÿ300ÿ487 freemarker-2.3.22.jar
23/11/2013  17:55   614ÿ203 javassist-3.11.0.GA.jar
28/05/2015  07:51   135ÿ903 log4j-api-2.3.jar
01/09/2015  10:46   827ÿ024 log4j-core-2.3(1).jar
07/04/2015  12:37   229ÿ218 ognl-3.0.11.jar
17/07/2015  09:46    69ÿ065 struts2-convention-plugin-2.5-BETA1.jar
17/07/2015  09:42 1ÿ517ÿ057 struts2-core-2.5-BETA1.jar


02/09/2015  14:07   477ÿ382 hibernate-validator-4.3.1.Final.jar
17/07/2015  09:56    24ÿ583 struts2-bean-validation-plugin-2.5-BETA1.jar

15/04/2014  14:57    63ÿ777 validation-api-1.1.0.Final.jar
 


 Le Mercredi 2 septembre 2015 15h48, Chris  a écrit :
   

 Thank you, 
so I added the right 4.3.1.Final version but I also need app-validation.

 Then I noticed that even if the application starts, unfortunately the tests in 
the form are not controled. Everything happens as if there were no control !.
 See ... without parameters..Updated Information
Your information:
First Name:  |  Last Name:  |  Favorite Sport: basketball |  Gender: not sure | 
 Residency: KS |  Over 21: false |  Car models: [] |  Email:  |  Phone: 
Return to home page.
Extracts : 
2015-09-02 15:18:25,588 WARN  [http-bio-8080-exec-9] 
interceptor.DefaultBeanValidationManager (DefaultBeanValidationManager.java:80) 
- ** No bean validator class defined - Falling back to default provider 
**Extracts :2015-09-02 15:18:25,605 ERROR [http-bio-8080-exec-9] 
providers.InterceptorBuilder (InterceptorBuilder.java:75) - Unable to load 
config class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
com.opensymphony.xwork2.config.ConfigurationException: Caught Exception while 
registering Interceptor class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
    at 
com.opensymphony.xwork2.factory.DefaultInterceptorFactory.buildInterceptor(DefaultInterceptorFactory.java:69)
 ~[struts2-core-2.5-BETA1.jar:2.5-BETA1]
    at 
com.opensymphony.xwork2.ObjectFactory.buildInterceptor(ObjectFactory.java:198) 
~[struts2-core-2.5-BETA1.jar:2.5-BETA1]


2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (jakarta) for 
(org.apache.struts2.dispatcher.multipart.MultiPartRequest)
2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(org.apache.struts2.views.freemarker.FreemarkerManager)
2015-09-02 15:18:25,348 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.validator.ActionValidatorManager)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory)
2015-09-02 15:18:25,350 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionProvider)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionContextFactory)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.dispatcher.StaticContentLoader)
2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.UnknownHandlerManager)
2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider 

Re: about struts-examples https://github.com/apache/struts-examples

2015-09-02 Thread Chris
Same things renamming 
01/09/2015  10:46   827ÿ024 log4j-core-2.3(1).jarin 01/09/2015  10:46   
    827ÿ024 log4j-core-2.3.jar 


 Le Mercredi 2 septembre 2015 16h09, Chris  a écrit :
   

 I am using the files23/11/2013  17:55    43ÿ578 asm-3.3.jar
23/11/2013  17:55    38ÿ275 asm-commons-3.3.jar
23/11/2013  17:55    21ÿ503 asm-tree-3.3.jar
19/02/2014  16:21    69ÿ002 commons-fileupload-1.3.1.jar
04/04/2014  11:19   185ÿ140 commons-io-2.4.jar
10/06/2015  07:51   434ÿ678 commons-lang3-3.4.jar
03/04/2015  07:09 1ÿ300ÿ487 freemarker-2.3.22.jar
23/11/2013  17:55   614ÿ203 javassist-3.11.0.GA.jar
28/05/2015  07:51   135ÿ903 log4j-api-2.3.jar
01/09/2015  10:46   827ÿ024 log4j-core-2.3(1).jar
07/04/2015  12:37   229ÿ218 ognl-3.0.11.jar
17/07/2015  09:46    69ÿ065 struts2-convention-plugin-2.5-BETA1.jar
17/07/2015  09:42 1ÿ517ÿ057 struts2-core-2.5-BETA1.jar


02/09/2015  14:07   477ÿ382 hibernate-validator-4.3.1.Final.jar
17/07/2015  09:56    24ÿ583 struts2-bean-validation-plugin-2.5-BETA1.jar

15/04/2014  14:57    63ÿ777 validation-api-1.1.0.Final.jar
 


 Le Mercredi 2 septembre 2015 15h48, Chris  a écrit :
   

 Thank you, 
so I added the right 4.3.1.Final version but I also need app-validation.

 Then I noticed that even if the application starts, unfortunately the tests in 
the form are not controled. Everything happens as if there were no control !.
 See ... without parameters..Updated Information
Your information:
First Name:  |  Last Name:  |  Favorite Sport: basketball |  Gender: not sure | 
 Residency: KS |  Over 21: false |  Car models: [] |  Email:  |  Phone: 
Return to home page.
Extracts : 
2015-09-02 15:18:25,588 WARN  [http-bio-8080-exec-9] 
interceptor.DefaultBeanValidationManager (DefaultBeanValidationManager.java:80) 
- ** No bean validator class defined - Falling back to default provider 
**Extracts :2015-09-02 15:18:25,605 ERROR [http-bio-8080-exec-9] 
providers.InterceptorBuilder (InterceptorBuilder.java:75) - Unable to load 
config class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
com.opensymphony.xwork2.config.ConfigurationException: Caught Exception while 
registering Interceptor class 
org.apache.struts.beanvalidation.validation.interceptor.BeanValidationInterceptor
    at 
com.opensymphony.xwork2.factory.DefaultInterceptorFactory.buildInterceptor(DefaultInterceptorFactory.java:69)
 ~[struts2-core-2.5-BETA1.jar:2.5-BETA1]
    at 
com.opensymphony.xwork2.ObjectFactory.buildInterceptor(ObjectFactory.java:198) 
~[struts2-core-2.5-BETA1.jar:2.5-BETA1]


2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (jakarta) for 
(org.apache.struts2.dispatcher.multipart.MultiPartRequest)
2015-09-02 15:18:25,346 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(org.apache.struts2.views.freemarker.FreemarkerManager)
2015-09-02 15:18:25,348 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.components.UrlRenderer)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.validator.ActionValidatorManager)
2015-09-02 15:18:25,349 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.ValueStackFactory)
2015-09-02 15:18:25,350 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionProvider)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for 
(com.opensymphony.xwork2.util.reflection.ReflectionContextFactory)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (com.opensymphony.xwork2.util.PatternMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.util.ContentTypeMatcher)
2015-09-02 15:18:25,351 INFO  [http-bio-8080-exec-9] 
config.AbstractBeanSelectionProvider (AbstractBeanSelectionProvider.java:49) - 
Choosing bean (struts) for (org.apache.struts2.dispatcher.StaticContentLoader)
2015-09-02 15:18:25,352 INFO  [http-bio-8080-exec-9] 

about struts-examples https://github.com/apache/struts-examples

2015-09-01 Thread Chris
Hello, 
It seems there are some new examples in apache/struts-examplesFrom A to Z1 ) 
bean-validation2 ) blank3 ) jboss-blanc4 ) mailreader5 ) restful2actionmapper6) 
themes_override
About 
1 ) bean-validationIt seems we need 2 jar  ( validation-api-1.1.0.Final.jar and 
hibernate ? ) 
bean-validation.
1 ) org.apache.struts.edit.action.EditAction.java   needs ->  
javax.validation.*    ( validation-api-1.1.0.Final.jar OK in package stuts2.5 
BETA1 )
2 ) org.apache.struts.edit.model;Person;java    
needs ->  javax.validation.constraints.*    ( validation-api-1.1.0.Final.jar ) 
OK
                    AND      ->  org.hibernate.validator.constraints.*
What do you think ? 
Regards
chris

|   |
|   |  |   |   |   |   |   |
| apache/struts-examplesstruts-examples - Mirror of Apache Struts |
|  |
| Afficher sur github.com | Aperçu par Yahoo |
|  |
|   |




Questions about struts dev mode.

2009-12-14 Thread Gustavo Felisberto
I have added devmode to my struts.xml:

 

struts

constant name=struts.devMode value=true/

.

/struts

 

If I go to a action that is not maped I get a very detailed error message.
But that is about it.

For example in a jsp I have:

 

s:form action=ActsAdd theme=simple

s:actionerror/

s:actionmessage/

s:radio list=denunceOtherId name=denunceOtheIdTypes/

s:textfield name=name/

/s:form

 

But the action does not have any getter for the list. If I run the code in
the debugger I see some sort of error being generated, but nothing in the
page.

 

The other thing is that there is also no setName(String name) in the action.
And I get no information about the missing setter.

 

Am I missing something?

 

-- 

Gustavo Felisberto.

WIT-Software, Lda

Coimbra (Portugal), San Jose (California)

Phone: +351239801030

Web:  http://www.wit-software.com http://www.wit-software.com 

 



RE: Question about struts templates

2009-11-20 Thread Raghuveer.V
Alternatively if you want to do only in one page

s:form action=helloWorld* theme=simple

Regards,
Raghuveer Vellanki
-Original Message-
From: Oscar [mailto:oscar.kalde...@gmail.com] 
Sent: Friday, November 20, 2009 5:06 AM
To: Struts Users Mailing List
Subject: Re: Question about struts templates

Thanks for your answer Burton. I didn't know how to do that but for 
others that could have that problem to the way to do this is the next:

Declare a constant in struts.xml like this:

constant name=struts.ui.theme value=simple /

Burton Rhodes escribió:
 Use the 'simple' theme. It just prints the HTML tag.

 On 11/19/09, Oscar oscar.kalde...@gmail.com wrote:
   
 Hi to all, i have a problem with struts 2 templates. The problem is that
 when i put a s:submit in my jsp for example, it automatically creates a
 div containing the submit and a new column in the table, and i don't
 want that, i only want only the button. Is there a way to tell struts
 that i don' want to use any template?

 Thanks in advance

 -
 To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
 For additional commands, e-mail: user-h...@struts.apache.org


 

 -
 To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
 For additional commands, e-mail: user-h...@struts.apache.org


   



-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Question about struts templates

2009-11-19 Thread Oscar
Hi to all, i have a problem with struts 2 templates. The problem is that 
when i put a s:submit in my jsp for example, it automatically creates a 
div containing the submit and a new column in the table, and i don't 
want that, i only want only the button. Is there a way to tell struts 
that i don' want to use any template?


Thanks in advance

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: Question about struts templates

2009-11-19 Thread Burton Rhodes
Use the 'simple' theme. It just prints the HTML tag.

On 11/19/09, Oscar oscar.kalde...@gmail.com wrote:
 Hi to all, i have a problem with struts 2 templates. The problem is that
 when i put a s:submit in my jsp for example, it automatically creates a
 div containing the submit and a new column in the table, and i don't
 want that, i only want only the button. Is there a way to tell struts
 that i don' want to use any template?

 Thanks in advance

 -
 To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
 For additional commands, e-mail: user-h...@struts.apache.org



-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: Question about struts templates

2009-11-19 Thread Oscar
Thanks for your answer Burton. I didn't know how to do that but for 
others that could have that problem to the way to do this is the next:


Declare a constant in struts.xml like this:

constant name=struts.ui.theme value=simple /

Burton Rhodes escribió:

Use the 'simple' theme. It just prints the HTML tag.

On 11/19/09, Oscar oscar.kalde...@gmail.com wrote:
  

Hi to all, i have a problem with struts 2 templates. The problem is that
when i put a s:submit in my jsp for example, it automatically creates a
div containing the submit and a new column in the table, and i don't
want that, i only want only the button. Is there a way to tell struts
that i don' want to use any template?

Thanks in advance

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org





-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org


  


-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: About Struts Rest Plugin

2008-12-23 Thread Luis Gervaso
no comments? :(

On Tue, Dec 23, 2008 at 3:05 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I'm wondering why not the behaviour of the rest plugin is ...

 *For example*

 URL:
 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5

 creates a mapping parent  child

 i.e:

 parentId: resource1/resource2/resource3/resource4
 childId: resource5

 these can be obtained from request URI

 now in the logic of the RestController we are aware to map these ids
 (really paths) with the model

 ParentObject - getFrom(parentId)
 ChildObject - getFrom(childId)

 This way to create new rest services we have to extend this base class

 *Another example*


 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/editNew

 parentId : resource1/resource2/resource3/resource4
 childId: a new ModelObject from the specific restController (which extends
 BaseRestController)

 *The create method *

 uses the post request parameters for the child
 uses the url to locate the parent

 I have put here childId or parentId, BUT really are ChildPath or ParentPath
 (the ids are for databases)

 if we need to use this concept may be more appropiate to use the term
 Reference

 Thanks for readme

 Luis
 --
 ---
 Luis Alberto Gervaso Martin
 Java EE Architect  Instructor
 C/ Cuenca 4A, 2ºB
 Getafe (Madrid)
 SPAIN
 mobile: (+34) 627983344
 luis.gerv...@gmail.com




-- 
---
Luis Alberto Gervaso Martin
Java EE Architect  Instructor
C/ Cuenca 4A, 2ºB
Getafe (Madrid)
SPAIN
mobile: (+34) 627983344
luis.gerv...@gmail.com


About Struts Rest Plugin

2008-12-22 Thread Luis Gervaso
I'm wondering why not the behaviour of the rest plugin is ...

*For example*

URL:
http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5

creates a mapping parent  child

i.e:

parentId: resource1/resource2/resource3/resource4
childId: resource5

these can be obtained from request URI

now in the logic of the RestController we are aware to map these ids (really
paths) with the model

ParentObject - getFrom(parentId)
ChildObject - getFrom(childId)

This way to create new rest services we have to extend this base class

*Another example*

http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/editNew

parentId : resource1/resource2/resource3/resource4
childId: a new ModelObject from the specific restController (which extends
BaseRestController)

*The create method *

uses the post request parameters for the child
uses the url to locate the parent

I have put here childId or parentId, BUT really are ChildPath or ParentPath
(the ids are for databases)

if we need to use this concept may be more appropiate to use the term
Reference

Thanks for readme

Luis
-- 
---
Luis Alberto Gervaso Martin
Java EE Architect  Instructor
C/ Cuenca 4A, 2ºB
Getafe (Madrid)
SPAIN
mobile: (+34) 627983344
luis.gerv...@gmail.com


Re: About Struts Rest Plugin

2008-12-22 Thread Luis Gervaso
I have been trying to figure the solution,

I'm using convention plugin and i need to map first every first child of
http://www.domain.com/myapp/restController/http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5to
a restaction

so

http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file1
http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file2

both to FileSystemRestController (which inherit from AbstractRestController)

AND

http://www.domain.com/myapp/restController/roles/user1/role1/subrole1
http://www.domain.com/myapp/restController/roles/user2/role1/subrole1
http://www.domain.com/myapp/restController/roles/user3/role1/subrole2

both to RolesRestController

these are just an example

the main purpose of this is be able to use

curl -X POST
http://www.domain.com/myapp/restController/roles/user1/role1/subrole1/othermorerole

and create othermorerole under
http://www.domain.com/myapp/restController/roles/user1/role1/subrole1



On Tue, Dec 23, 2008 at 3:05 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I'm wondering why not the behaviour of the rest plugin is ...

 *For example*

 URL:
 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5

 creates a mapping parent  child

 i.e:

 parentId: resource1/resource2/resource3/resource4
 childId: resource5

 these can be obtained from request URI

 now in the logic of the RestController we are aware to map these ids
 (really paths) with the model

 ParentObject - getFrom(parentId)
 ChildObject - getFrom(childId)

 This way to create new rest services we have to extend this base class

 *Another example*


 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/editNew

 parentId : resource1/resource2/resource3/resource4
 childId: a new ModelObject from the specific restController (which extends
 BaseRestController)

 *The create method *

 uses the post request parameters for the child
 uses the url to locate the parent

 I have put here childId or parentId, BUT really are ChildPath or ParentPath
 (the ids are for databases)

 if we need to use this concept may be more appropiate to use the term
 Reference

 Thanks for readme

 Luis
 --
 ---
 Luis Alberto Gervaso Martin
 Java EE Architect  Instructor
 C/ Cuenca 4A, 2ºB
 Getafe (Madrid)
 SPAIN
 mobile: (+34) 627983344
 luis.gerv...@gmail.com




-- 
---
Luis Alberto Gervaso Martin
Java EE Architect  Instructor
C/ Cuenca 4A, 2ºB
Getafe (Madrid)
SPAIN
mobile: (+34) 627983344
luis.gerv...@gmail.com


Re: About Struts Rest Plugin

2008-12-22 Thread Luis Gervaso
OK with convention plugin is possible to do

code from RestAction

@Action(value=/rest/*,
result...@result(name=BaseAction.SUCCESS,
location=/WEB-INF/content/rest-success.jsp)}
)
public final String execute() {
System.out.println();
System.out.println(PARENT :  + getParentPath());
System.out.println(RESOURCE :  + getResourceName());


//examine http method and other stuff

return HttpBaseAction.SUCCESS;
}

now the requestURI returns

/contextPath/rest/folder1/folder2/folder3/file1

contextPath is fixed length OK
rest is annotated (is possible access without reflection? may be from the
current ActionContext?) 
getParentPath returns folder1/folder2/folder3 (from /* to last /) OK
getResourceName file1

Here is the fast code for getParentPath() and getResourceName() [UNSOLVED
the Action current name]

protected String getRequestURI() {
String uri = getRequest().getRequestURI();
return (uri.charAt(uri.length() - 1) == '/') ?
uri.substring(0,uri.length() - 1) : uri;
}

protected String getParentPath() {
String parentPath =
getRequestURI().substring(getContextPath().length(),getRequestURI().lastIndexOf('/'));
if (parentPath.length()  1) parentPath = /;
return parentPath;
}

protected String getResourceName() {
String resourceName =
getRequestURI().substring(getContextPath().concat(getParentPath()).length());
return resourceName.charAt(0) == '/' ? resourceName.substring(1) :
resourceName;
}




On Tue, Dec 23, 2008 at 6:45 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I have been trying to figure the solution,

 I'm using convention plugin and i need to map first every first child of
 http://www.domain.com/myapp/restController/http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5to
  a restaction

 so


 http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file1

 http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file2

 both to FileSystemRestController (which inherit from
 AbstractRestController)

 AND

 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1
 http://www.domain.com/myapp/restController/roles/user2/role1/subrole1
 http://www.domain.com/myapp/restController/roles/user3/role1/subrole2

 both to RolesRestController

 these are just an example

 the main purpose of this is be able to use

 curl -X POST
 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1/othermorerole

 and create othermorerole under
 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1




 On Tue, Dec 23, 2008 at 3:05 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I'm wondering why not the behaviour of the rest plugin is ...

 *For example*

 URL:
 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5

 creates a mapping parent  child

 i.e:

 parentId: resource1/resource2/resource3/resource4
 childId: resource5

 these can be obtained from request URI

 now in the logic of the RestController we are aware to map these ids
 (really paths) with the model

 ParentObject - getFrom(parentId)
 ChildObject - getFrom(childId)

 This way to create new rest services we have to extend this base class

 *Another example*


 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/editNew

 parentId : resource1/resource2/resource3/resource4
 childId: a new ModelObject from the specific restController (which extends
 BaseRestController)

 *The create method *

 uses the post request parameters for the child
 uses the url to locate the parent

 I have put here childId or parentId, BUT really are ChildPath or
 ParentPath (the ids are for databases)

 if we need to use this concept may be more appropiate to use the term
 Reference

 Thanks for readme

 Luis
 --
 ---
 Luis Alberto Gervaso Martin
 Java EE Architect  Instructor
 C/ Cuenca 4A, 2ºB
 Getafe (Madrid)
 SPAIN
 mobile: (+34) 627983344
  luis.gerv...@gmail.com




 --
 ---
 Luis Alberto Gervaso Martin
 Java EE Architect  Instructor
 C/ Cuenca 4A, 2ºB
 Getafe (Madrid)
 SPAIN
 mobile: (+34) 627983344
 luis.gerv...@gmail.com




-- 
---
Luis Alberto Gervaso Martin
Java EE Architect  Instructor
C/ Cuenca 4A, 2ºB
Getafe (Madrid)
SPAIN
mobile: (+34) 627983344
luis.gerv...@gmail.com


Re: About Struts Rest Plugin

2008-12-22 Thread Luis Gervaso
The reflection impl

import java.lang.reflect.Method;

import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Result;


public class RestAction extends HttpBaseAction {

@Action(value=/rest/*,
result...@result(name=HttpBaseAction.SUCCESS,
location=/WEB-INF/content/rest-success.jsp)}
)
public final String execute() throws Exception {
System.out.println();
System.out.println(PARENT :  + getParentPath());
System.out.println(RESOURCE :  + getResourceName());
return HttpBaseAction.SUCCESS;
}

// GET /rest/1
public String show() {
return HttpBaseAction.SUCCESS;
}

// GET /rest/
public String index() {

//list = ordersService.getAll();
return HttpBaseAction.SUCCESS;
}

// POST /rest
public String create() {
System.out.println(create  + getResourceName());
//ordersService.save(model);
addActionMessage(New order created successfully);
return HttpBaseAction.SUCCESS;
}

public String getParentPath() throws SecurityException,
NoSuchMethodException {
Method m = this.getClass().getMethod(execute, null);
Action aa = m.getAnnotation(Action.class);
int valueLength = aa.value().substring(0,
aa.value().lastIndexOf('/')).length();
String parentPath =
getRequestURI().substring(getContextPath().length() + valueLength,
getRequestURI().lastIndexOf('/'));
return parentPath;
}

public String getResourceName() {
return getRequestURI().substring(getRequestURI().lastIndexOf('/') +
1);
}


}

The output:

curl http://localhost:8080/context/rest/2/1/4553/45

PARENT : /2/1/4553
RESOURCE : 45

On Tue, Dec 23, 2008 at 7:25 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 OK with convention plugin is possible to do

 code from RestAction

 @Action(value=/rest/*,
 result...@result(name=BaseAction.SUCCESS,
 location=/WEB-INF/content/rest-success.jsp)}
 )
 public final String execute() {
 System.out.println();
 System.out.println(PARENT :  + getParentPath());
 System.out.println(RESOURCE :  + getResourceName());


 //examine http method and other stuff

 return HttpBaseAction.SUCCESS;
 }

 now the requestURI returns

 /contextPath/rest/folder1/folder2/folder3/file1

 contextPath is fixed length OK
 rest is annotated (is possible access without reflection? may be from the
 current ActionContext?) 
 getParentPath returns folder1/folder2/folder3 (from /* to last /) OK
 getResourceName file1

 Here is the fast code for getParentPath() and getResourceName() [UNSOLVED
 the Action current name]

 protected String getRequestURI() {
 String uri = getRequest().getRequestURI();
 return (uri.charAt(uri.length() - 1) == '/') ?
 uri.substring(0,uri.length() - 1) : uri;
 }

 protected String getParentPath() {
 String parentPath =
 getRequestURI().substring(getContextPath().length(),getRequestURI().lastIndexOf('/'));
 if (parentPath.length()  1) parentPath = /;
 return parentPath;
 }

 protected String getResourceName() {
 String resourceName =
 getRequestURI().substring(getContextPath().concat(getParentPath()).length());
 return resourceName.charAt(0) == '/' ? resourceName.substring(1) :
 resourceName;

 }




 On Tue, Dec 23, 2008 at 6:45 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I have been trying to figure the solution,

 I'm using convention plugin and i need to map first every first child of
 http://www.domain.com/myapp/restController/http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5to
  a restaction

 so


 http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file1

 http://www.domain.com/myapp/restController/fileSystem/folder1/folder2/folder3/file2

 both to FileSystemRestController (which inherit from
 AbstractRestController)

 AND

 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1
 http://www.domain.com/myapp/restController/roles/user2/role1/subrole1
 http://www.domain.com/myapp/restController/roles/user3/role1/subrole2

 both to RolesRestController

 these are just an example

 the main purpose of this is be able to use

 curl -X POST
 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1/othermorerole

 and create othermorerole under
 http://www.domain.com/myapp/restController/roles/user1/role1/subrole1




 On Tue, Dec 23, 2008 at 3:05 AM, Luis Gervaso luis.gerv...@gmail.comwrote:

 I'm wondering why not the behaviour of the rest plugin is ...

 *For example*

 URL:
 http://www.domain.com/myapp/restController/resource1/resource2/resource3/resource4/resource5

 creates a mapping parent  child

 i.e:

 parentId: resource1/resource2/resource3/resource4
 childId: resource5

 these can be obtained from request URI

 now in the logic of the RestController we are 

2 newbie questions about Struts and JSP

2008-09-23 Thread UseTheFork

Hi, 

I am studying JSP and I understand that these pages are translated into java
code servlets, which are then compiled and executed on the application
server.

i) Do these 'JSP servlets' implement the HttpJspPage interface defined in
javax.servlet.jsp?

ii) Does Struts (or Spring MVC) provide implementation of such 'JSP
servlets'? Or does Strut (and Spring MVC) have nothing to do with this?

Thanks,

J.
-- 
View this message in context: 
http://www.nabble.com/2-newbie-questions-about-Struts-and-JSP-tp19627021p19627021.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: 2 newbie questions about Struts and JSP

2008-09-23 Thread Alberto Flores
If you are developing using Tomcat (hopefully you are), consider reading 
the comments (and documentation) on the Jasper 2 JSP Engine. 
Particularly look here:


http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html

Specifically, trying the flags keepgenerated will bring some light to 
your question. If you are using Eclipse (or any other decent IDE), also 
consider putting a break point in a jsp page and take a look at what the 
variables show you.  This will bring lots of goddies to your studying.


Concerning Struts (or Spring MVC), Struts 1.x and Spring MVC use a 
servlet to control incoming requests whereas Struts 2.x uses a Filter 
instead. They do not implement any JSP specific interface as they are 
not concern with JSP technology.


JSP is (IMHO) a rendering technology (think of it as a servlet that 
simply outputs HTML code to the output buffer writer).  Technically, 
it's the V in MVC. Granted you could do it with a servlet, but JSP was 
born with the idea that visualizing HTML mixed with Java code was easier 
to imagine instead of writing code like :


out.write(head/head);  etc, etc...

Servlets can be used to be the C of MVC (or at least help out). This 
is a distinction I've seen pretty much everywhere I've been (when you 
implement your own).  You could write your servlets to forward to other 
servlets (jsps) of use 3rd Party frameworks.  Frameworks like Struts 
1.x, 2.x or Spring MVC delegate this mechanism to simple class (Action, 
Controller, Pojo, etc) to do the processing continuing with the MVC 
pattern. The delegation to a rendering technology typically occurs 
within these frameworks where you have options (instead of simply 
relying on JPS, now you can choose in using Velocity, Freemarker, etc). 
I've been using the latter and I'm liking it very much.


Hope this helps!


UseTheFork wrote:
Hi, 


I am studying JSP and I understand that these pages are translated into java
code servlets, which are then compiled and executed on the application
server.

i) Do these 'JSP servlets' implement the HttpJspPage interface defined in
javax.servlet.jsp?

ii) Does Struts (or Spring MVC) provide implementation of such 'JSP
servlets'? Or does Strut (and Spring MVC) have nothing to do with this?

Thanks,

J.


--
--
Alberto
http://www.linkedin.com/in/aflores

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

Re: 2 newbie questions about Struts and JSP

2008-09-23 Thread UseTheFork

Hi Alberto, thank you for your answer !!! Very helpful !!!

J.



-- 
View this message in context: 
http://www.nabble.com/2-newbie-questions-about-Struts-and-JSP-tp19627021p19628686.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: [OT] Re: Newbie question about Struts HelloWorld example

2008-09-14 Thread UseTheFork

Hi Dave, 

The solution was in fact very simple
(http://www.nabble.com/Issue-with-deployment-on-Glassfish-td19463423.html#a19464284).
It was stupid from me to search for jars on the app server, because they are
packaged in containers. I knew it, but I forgot it in my stress...

Thanks for your help anyway,

J.
-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19478209.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]



Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

Hi, 

I am a newbie to Struts and I am trying to make the HelloWord example work
in Netbeans 6.1 (http://struts.apache.org/2.x/docs/hello-world.html). I have
implemented all files in a web project and it compiles fine. I have then
used the undeploy deploy functionality and got no error message. 

Next, I tried to browse: http://localhost:8080/tutorial/HelloWorld.action
and got a HTTP Status 404 description: The requested resource () is not
available. I am using GlassFish.

I have no idea why it does not work. Can anybody help? Give tips? Pointers?
Could it be a config issue?

Thank you,

J.
-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19451760.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: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 I have no idea why it does not work. Can anybody help? Give
 tips? Pointers? Could it be a config issue?

...

Sure, it could be a config issue.

Is there anything in the logs? Do you have devMode turned on?

Dave


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

Hi Dave,

 Is there anything in the logs? Do you have devMode turned on?

i) I don't know what devMode is, can you explain?

ii) I have noticed that I did not create my web.xml and struts.xml files
properly.
I have corrected that problem, compiled, undeployed and redeployed and I
still
have the same issue.

iii) The Glassfish Log contains tons of these kind of messages:

Timestamp

Sep 12, 2008 14:53:59.984
Log Level

INFO
Logger

javax.enterprise.system.stream.out
Name-Value Pairs

_ThreadID=590;_ThreadName=HTTP Monitor, sends data to IDE;
Record Number

1342
Message ID

Complete Message

WARNING *** NetBeans HTTP Monitor  The request cannot be
recorded most likely because the NetBeans HTTP Server is not running. Go to
the IDE and start the HTTP Server from within the Runtime window to fix this
problem.


When I refresh my browser with
http://localhost:8080/tutorial/HelloWorld.action, I do not get any WARNING
or SEVERE kind of messages in the Glassfish Logs. I only get more of the
above. I have also checked for CONFIG, FINE, FINER, FINEST messages, but I
don't get any. The Glassfish Admin Console is works fine, which make me
think that Glassfish is working fine !!!

Thank you for your time,

J.

-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19455428.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: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 i) I don't know what devMode is, can you explain?

http://struts.apache.org/2.x/docs/devmode.html

Without any more information it's essentially impossible to help. You'd be 
better served by posting your web.xml and struts.xml files here; I'm assuming 
they're still quite short.

Dave


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread Jeromy Evans

UseTheFork wrote:


When I refresh my browser with
http://localhost:8080/tutorial/HelloWorld.action, I do not get any WARNING
or SEVERE kind of messages in the Glassfish Logs. I only get more of the
above. I have also checked for CONFIG, FINE, FINER, FINEST messages, but I
don't get any. The Glassfish Admin Console is works fine, which make me
think that Glassfish is working fine !!!

  


The most common initial problem is usually:
 some of the jars are missing from the lib directory of your web 
application when ir's deployed; or
 the configuration is referencing something incorrectly (like an 
invalid classname)


The effect is that the struts filter (in your web.xml) fails to start.  
If it fails to start, you get the 404 error in the browser and no new 
messages logged (as struts isn't running).


As dave says, it's really imported to either find the logs that show 
struts failed to start, or started and rejected the config; or 
double-check the config and deployment.

(or post the config here as Dave suggested)


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

Here is my struts.xml:

!DOCTYPE struts PUBLIC
-//Apache Software Foundation//DTD Struts Configuration 2.0//EN
http://struts.apache.org/dtds/struts-2.0.dtd;
struts
constant name=struts.devMode value=true /
package name=tutorial extends=struts-default
action name=HelloWorld class=tutorial.HelloWorld
result/HelloWorld.jsp/result
/action
!-- Add your actions here --
/package
/struts

and my web.xml:

?xml version=1.0?
!DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application
2.3//EN
http://java.sun.com/dtd/web-app_2_3.dtd;

web-app
  display-nameMy Application/display-name
  filter
filter-namestruts2/filter-name
   
filter-classorg.apache.struts2.dispatcher.FilterDispatcher/filter-class
  /filter

  filter-mapping
filter-namestruts2/filter-name
url-pattern/*/url-pattern
  /filter-mapping
/web-app

You will notice in my struts.xml that devMode has been set to true. However,
I still don't get anything new in my Glassfish Logs. BUT, I have noticed
some issues when I start Glassfish:

http://www.nabble.com/file/p19457690/Log%2BList.png 

Thanks,

J.


-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19457690.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: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 You will notice in my struts.xml that devMode has been set 
 to true. However, I still don't get anything new in my 
 Glassfish Logs. BUT, I have noticed some issues when 
 I start Glassfish:
 
 http://www.nabble.com/file/p19457690/Log%2BList.png 

Looks like you're missing at least the commons-logging dependency; I'd make 
sure you're deploying all the appropriate dependencies.

Dave


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

Hi Dave, 

I have a library called commons-loggin in my project:

http://www.nabble.com/file/p19462329/Commons-loggin.png 

I had to fiddle with the Web Pages directory structure in the project and
create a Classes sub-directory to match the requirements mentioned on
http://struts.apache.org/2.x/docs/simple-setup.html. 

Could this be the source of my issue?

Thanks, 

J.
-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19462329.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: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 I have a library called commons-loggin in my project:

Is it being deployed?

 I had to fiddle with the Web Pages directory structure in
 the project and create a Classes sub-directory to match the 
 requirements mentioned on
 http://struts.apache.org/2.x/docs/simple-setup.html. 
 
 Could this be the source of my issue?

Of course it *could* be, but it's almost certainly not related to your 
deployment issues.

Right now it looks like you're missing some basics of JEE web app development, 
particularly deployment requirements. I'd search the fine web for that 
information. There may also be IDE-specific information you need to figure out.

Dave


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

 Is it being deployed?

I can't find the common jar in the App server installation directory. I will
open a ticket with Netbeans Nabble.

Thank you for your help,

J.
-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19463173.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: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 I asked:
 Is it being deployed?
 I can't find the common jar in the App server installation directory. 
 I will open a ticket with Netbeans Nabble.

This is [most likely] not a NetBeans issue, either, it's a project 
configuration and/or deployment issue. While I'm not a regular NetBeans user, 
I'm reasonably certain it's capable of deploying a web application when it's 
set up to do so.

Dave


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



Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread UseTheFork

Dave, 

I have managed to deploy another project two days ago without any issue. The
JSP pages worked fine. This time, I am trying to use Struts. It could be a
project configuration issue, I agree, but I have checked that and I don't
know what is wrong... I am in newbie exploration mode here !!!

The only main difference is that I need to include some additional jars
according to the struts example. I did that the 'usual' way in Netbeans. I
have a lot of experience with Java Standard Edition. May be someone from
Nabble - Netbeans knows what is happening...

Thanks for your help,

J.
-- 
View this message in context: 
http://www.nabble.com/Newbie-question-about-Struts-HelloWorld-example-tp19451760p19463840.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]



[OT] Re: Newbie question about Struts HelloWorld example

2008-09-12 Thread Dave Newton
--- On Fri, 9/12/08, UseTheFork wrote:
 I have managed to deploy another project two days
 ago without any issue. The JSP pages worked fine.

That doesn't require any additional web app libraries.

 It could be a project configuration issue, I agree, 
 but I have checked that and I don't know what is wrong... 

A web app requires that its dependencies be deployed to /WEB-INF/lib.

Dave


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



Re: Question about Struts 2 Flow Control

2008-01-31 Thread Laurie Harper

claym wrote:

One of the things I really liked about Spring MVC was the fact that it was
very easy to control the flow of a request. You could use referenceData() to
add data that was needed on the page but not necessarily form related, then
formBackingObject() for the actual pre-submission form population, and then
control the processing of pre-submit and post-submit with showForm() and
onSubmit()

It was also smart enough to repopulate things like referenceData if there
was an invalid submission.

Part of this was due to the fact that there were lots of different types of
controllers - all the referenceData and formBackingObject wasn't necessary
if you're just displaying a non-form page, but you could always use
SimpleFormController if you needed it.

I'm not seeing that kind of behavior in Struts 2. I'm not saying it's
required functionality, but I certainly appreciated it in Spring MVC.

Is it there and I'm not seeing it? How would you control the request like
this?


I don't know SpringMVC at all, but this all sounds like stuff that's 
easy to do with Struts2, as far as I understand your description.


Firstly, anything you expose via a getter method in your action is 
available from the page template, which I think takes care of the 
referenceData part. Perhaps also take a look at the Preparable 
interceptor and associated Preparable interface.


You can also use action getters for form population but if you prefer to 
keep the form related data separate you can. Either have a getter on the 
action that returns a reference to an object which holds the form data 
or, if you want to make things more explicit, you can use the Model 
Driven pattern (implementing a getModel() method on your action).


Doing different processing when showing the form vs. handling its 
submission is easy: put the logic in two different action methods. You 
can have one method invoked to display the form and invoke the other to 
processes it when submitted. You can also easily invoke a different 
method for each 'submit' button on the form if you need to.


Struts also knows how to automatically redisplay the input form if it's 
submitted with invalid data. With appropriate configuration, you can 
invoke the same logic you used to setup the form in the first place to 
provide that data that wasn't 'form related'.


I would suggest trying a simple test app to experiment with these 
workflows and coming back with specific questions. It's difficult to 
generalize about Struts equivalents to the features of an unfamiliar 
framework :-)


L.


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



Question about Struts 2 Flow Control

2008-01-30 Thread claym

One of the things I really liked about Spring MVC was the fact that it was
very easy to control the flow of a request. You could use referenceData() to
add data that was needed on the page but not necessarily form related, then
formBackingObject() for the actual pre-submission form population, and then
control the processing of pre-submit and post-submit with showForm() and
onSubmit()

It was also smart enough to repopulate things like referenceData if there
was an invalid submission.

Part of this was due to the fact that there were lots of different types of
controllers - all the referenceData and formBackingObject wasn't necessary
if you're just displaying a non-form page, but you could always use
SimpleFormController if you needed it.

I'm not seeing that kind of behavior in Struts 2. I'm not saying it's
required functionality, but I certainly appreciated it in Spring MVC.

Is it there and I'm not seeing it? How would you control the request like
this?
-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-2-Flow-Control-tp15190024p15190024.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: Question about Struts 2 Flow Control

2008-01-30 Thread Musachy Barroso
I am feeling really dumb now, that doesn't sound very easy at all
:). Could you re-write your question for non-spring mvc  users?

musachy

On Jan 30, 2008 2:36 PM, claym [EMAIL PROTECTED] wrote:

 One of the things I really liked about Spring MVC was the fact that it was
 very easy to control the flow of a request. You could use referenceData() to
 add data that was needed on the page but not necessarily form related, then
 formBackingObject() for the actual pre-submission form population, and then
 control the processing of pre-submit and post-submit with showForm() and
 onSubmit()

 It was also smart enough to repopulate things like referenceData if there
 was an invalid submission.

 Part of this was due to the fact that there were lots of different types of
 controllers - all the referenceData and formBackingObject wasn't necessary
 if you're just displaying a non-form page, but you could always use
 SimpleFormController if you needed it.

 I'm not seeing that kind of behavior in Struts 2. I'm not saying it's
 required functionality, but I certainly appreciated it in Spring MVC.

 Is it there and I'm not seeing it? How would you control the request like
 this?
 --
 View this message in context: 
 http://www.nabble.com/Question-about-Struts-2-Flow-Control-tp15190024p15190024.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]





-- 
Hey you! Would you help me to carry the stone? Pink Floyd

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



Re: Question about Struts 2 Flow Control

2008-01-30 Thread WongTseng
actually, S2 have a equivelent to spring's command object. S2 can
populate the model object for you, if you get right interceptor. and
when a invalid submissiom comes in, s2 action can forward you back to
the input page with error messages. s2 also has an oblivious advantage
against spring mvc, that is s2 can do whatever spring mvc can do with
only one type of action.

2008/1/30, Musachy Barroso [EMAIL PROTECTED]:
 I am feeling really dumb now, that doesn't sound very easy at all
 :). Could you re-write your question for non-spring mvc  users?

 musachy

 On Jan 30, 2008 2:36 PM, claym [EMAIL PROTECTED] wrote:
 
  One of the things I really liked about Spring MVC was the fact that it was
  very easy to control the flow of a request. You could use referenceData()
 to
  add data that was needed on the page but not necessarily form related,
 then
  formBackingObject() for the actual pre-submission form population, and
 then
  control the processing of pre-submit and post-submit with showForm() and
  onSubmit()
 
  It was also smart enough to repopulate things like referenceData if there
  was an invalid submission.
 
  Part of this was due to the fact that there were lots of different types
 of
  controllers - all the referenceData and formBackingObject wasn't necessary
  if you're just displaying a non-form page, but you could always use
  SimpleFormController if you needed it.
 
  I'm not seeing that kind of behavior in Struts 2. I'm not saying it's
  required functionality, but I certainly appreciated it in Spring MVC.
 
  Is it there and I'm not seeing it? How would you control the request like
  this?
  --
  View this message in context:
 http://www.nabble.com/Question-about-Struts-2-Flow-Control-tp15190024p15190024.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]
 
 



 --
 Hey you! Would you help me to carry the stone? Pink Floyd

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




-- 
Best Regards
Wong Tseng

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



question about struts 2 s:textfield and table layout

2008-01-16 Thread Wei, Mei
Hi,

 

I am wondering in the Validation example quiz-ajax.jsp (which is in the
struts 2.0's tutorial showcase
http://www.planetstruts.org/struts2-showcase/showcase.action), is there
a way to arrange the table into two columns. That means to make field
name and age on the same row.

 

Here is the snippet from quiz-ajax.jsp

%@ taglib prefix=s uri=/struts-tags %

 

!-- START SNIPPET: ajaxValidation --

 

html

head

titleValidation - Basic/title

s:head theme=ajax/

/head

 

body

 

s:form method=post validate=true theme=ajax

s:textfield label=Name name=name/

s:textfield label=Age name=age/

s:textfield label=Favorite color name=answer/

s:submit/

/s:form

 

/body

/html

 

!-- END SNIPPET: ajaxValidation --

 

Any help is appreciated.

Thanks,

Mei 



Re: question about struts 2 s:textfield and table layout

2008-01-16 Thread Dave Newton
--- Wei, Mei [EMAIL PROTECTED] wrote:
 [...] is there a way to arrange the table into two columns.

You'll want to explore themes and templates [1].

The nutshell version is that you'll probably want to either (a) use the
simple theme on your s:textfield.../ elements or (b) modify a template.
The default theme, as you've noticed, assumes a one-field-per-row layout.

One disadvantage of using the simple theme is that you'll lose some of the
automagic error handling provided in the default theme.

d.

[1] http://struts.apache.org/2.x/docs/themes-and-templates.html
[tags: s2, themes, forms, form tags]



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



about struts, xml and xslt

2007-12-03 Thread logancillo

Good days people, I need your help and experience. Could you recommend me
some way to do some xslt work? Something as the tag xmlTemplate that has
MyFaces in which you can provide the xml in brute and the xsl in brute and
the result is html, xhtml, etc...

I could use any thing, but but if they are librarys used in systems in
production, better.


thx a lot

-- 
View this message in context: 
http://www.nabble.com/about-struts%2C-xml-and-xslt-tf4935381.html#a14126590
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: about struts, xml and xslt

2007-12-03 Thread Laurie Harper

logancillo wrote:

Good days people, I need your help and experience. Could you recommend me
some way to do some xslt work? Something as the tag xmlTemplate that has
MyFaces in which you can provide the xml in brute and the xsl in brute and
the result is html, xhtml, etc...

I could use any thing, but but if they are librarys used in systems in
production, better.


I assume you mean using Struts... For Struts 2, look at the XSL Result 
[1] for a starting point. Googling for 'struts xsl' will also give you a 
wealth of resources to investigate.


L.

[1] http://struts.apache.org/2.x/docs/xsl-result.html


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



Re: about Struts 2.0.9 portlet example ...

2007-10-24 Thread Guillaume Bilodeau

Ok thanks, that's good to know.

There is a strong recommendation coming from a colleague to use the IBM
Portlet API on WebSphere Portal, particularly because of its support for
inter-portlet communication - from what I'm told, this isn't supported by
the standard JSR-168 API.  I'm not too keen on using proprietary extensions,
unless it does provide a significant advantage.  Would Struts2 provide the
necessary mechanism to accomplish this communication?  What are the
advantages of using Struts2 on top of the standard portlet API or the IBM
API?

Thanks again,
GB


Nils-Helge Garli wrote:
 
 The portlet support in the next 2.0.x and 2.1.x has been improved a
 lot. You can browse the changelogs and remaining issues in the issue
 tracker. It does not include Ajax support, but you can add that
 yourself. I know of several projects that are using it in production
 already.
 
 Nils-H
 
 On 10/23/07, Guillaume Bilodeau [EMAIL PROTECTED] wrote:

 We will soon start a portal project and we're evaluating the technologies
 available to us.  Is Struts2 support for portlets ready for primetime, or
 should we use something else until it's stabilized?

 Cheers,
 GB


 Nils-Helge Garli wrote:
 
  Hi!
 
  If you're thinking of the struts2-portlet application, you need to
  install it into a portlet container to test it. However, ajax is not
  yet built into the portlet framework.
 
  Nils-H
 
  On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
  hi all,
 
  I managed to see the examples in the portlet webapp demo (there is no
  index page) but I didn't see any portlet anywhere ... so I am curious
 as
  if to there is at all an AJAX portlet control delivered with Struts 2?
 
  Lack of portlets in S2 and AJAxification of displaytag would be the
 two
  main reasons for me to use ajaxtags in addition to S2.
  Any alternatives to ajaxtags?
 
  regards,
  Giovanni
 
 
  -
  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]
 
 
 

 --
 View this message in context:
 http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13356144
 Sent from the Struts - User mailing list archive at Nabble.com.


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

-- 
View this message in context: 
http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13394151
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: about Struts 2.0.9 portlet example ...

2007-10-24 Thread Nils-Helge Garli Hegvik
It is true that inter portlet communication is not supported in the
JSR168 spec, but there are ways to exchange data between portlets in a
less proprietary manner. The easiest way is to use the shared session
scope which is available to all portlets in the same portlet
application (same war file). So if you have portlets that need to
communicate, put them in the same application (which they probably
should anyway, since they obviously have some relation). Without
having tried it, you might also be able to build something on top of a
distributed caching/JMS/database system.

The Portlet 2.0 (JSR 286) specification includes support for inter
portlet communication.

The main advantage using Struts 2 (or any web framework that support
portlets) is that you get a framework on top of the portlet API. I am
not aware of any framework support for the IBM Portlet API (besides a
custom struts framework that really wasn't any good the last time I
tried it), so it would be like programming servlets in a web
application. But still, if you know that inter portlet communication
will be important for your application, and none of the proposed
solutions are good enough for you to use, I guess you don't have a
choice but lock yourself to a vendor.

Nils-H

On 10/24/07, Guillaume Bilodeau [EMAIL PROTECTED] wrote:

 Ok thanks, that's good to know.

 There is a strong recommendation coming from a colleague to use the IBM
 Portlet API on WebSphere Portal, particularly because of its support for
 inter-portlet communication - from what I'm told, this isn't supported by
 the standard JSR-168 API.  I'm not too keen on using proprietary extensions,
 unless it does provide a significant advantage.  Would Struts2 provide the
 necessary mechanism to accomplish this communication?  What are the
 advantages of using Struts2 on top of the standard portlet API or the IBM
 API?

 Thanks again,
 GB


 Nils-Helge Garli wrote:
 
  The portlet support in the next 2.0.x and 2.1.x has been improved a
  lot. You can browse the changelogs and remaining issues in the issue
  tracker. It does not include Ajax support, but you can add that
  yourself. I know of several projects that are using it in production
  already.
 
  Nils-H
 
  On 10/23/07, Guillaume Bilodeau [EMAIL PROTECTED] wrote:
 
  We will soon start a portal project and we're evaluating the technologies
  available to us.  Is Struts2 support for portlets ready for primetime, or
  should we use something else until it's stabilized?
 
  Cheers,
  GB
 
 
  Nils-Helge Garli wrote:
  
   Hi!
  
   If you're thinking of the struts2-portlet application, you need to
   install it into a portlet container to test it. However, ajax is not
   yet built into the portlet framework.
  
   Nils-H
  
   On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
   hi all,
  
   I managed to see the examples in the portlet webapp demo (there is no
   index page) but I didn't see any portlet anywhere ... so I am curious
  as
   if to there is at all an AJAX portlet control delivered with Struts 2?
  
   Lack of portlets in S2 and AJAxification of displaytag would be the
  two
   main reasons for me to use ajaxtags in addition to S2.
   Any alternatives to ajaxtags?
  
   regards,
   Giovanni
  
  
   -
   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]
  
  
  
 
  --
  View this message in context:
  http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13356144
  Sent from the Struts - User mailing list archive at Nabble.com.
 
 
  -
  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]
 
 
 

 --
 View this message in context: 
 http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13394151
 Sent from the Struts - User mailing list archive at Nabble.com.


 -
 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: about Struts 2.0.9 portlet example ...

2007-10-22 Thread Guillaume Bilodeau

We will soon start a portal project and we're evaluating the technologies
available to us.  Is Struts2 support for portlets ready for primetime, or
should we use something else until it's stabilized?

Cheers,
GB


Nils-Helge Garli wrote:
 
 Hi!
 
 If you're thinking of the struts2-portlet application, you need to
 install it into a portlet container to test it. However, ajax is not
 yet built into the portlet framework.
 
 Nils-H
 
 On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
 hi all,

 I managed to see the examples in the portlet webapp demo (there is no
 index page) but I didn't see any portlet anywhere ... so I am curious as
 if to there is at all an AJAX portlet control delivered with Struts 2?

 Lack of portlets in S2 and AJAxification of displaytag would be the two
 main reasons for me to use ajaxtags in addition to S2.
 Any alternatives to ajaxtags?

 regards,
 Giovanni


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

-- 
View this message in context: 
http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13356144
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: about Struts 2.0.9 portlet example ...

2007-10-22 Thread Nils-Helge Garli Hegvik
The portlet support in the next 2.0.x and 2.1.x has been improved a
lot. You can browse the changelogs and remaining issues in the issue
tracker. It does not include Ajax support, but you can add that
yourself. I know of several projects that are using it in production
already.

Nils-H

On 10/23/07, Guillaume Bilodeau [EMAIL PROTECTED] wrote:

 We will soon start a portal project and we're evaluating the technologies
 available to us.  Is Struts2 support for portlets ready for primetime, or
 should we use something else until it's stabilized?

 Cheers,
 GB


 Nils-Helge Garli wrote:
 
  Hi!
 
  If you're thinking of the struts2-portlet application, you need to
  install it into a portlet container to test it. However, ajax is not
  yet built into the portlet framework.
 
  Nils-H
 
  On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
  hi all,
 
  I managed to see the examples in the portlet webapp demo (there is no
  index page) but I didn't see any portlet anywhere ... so I am curious as
  if to there is at all an AJAX portlet control delivered with Struts 2?
 
  Lack of portlets in S2 and AJAxification of displaytag would be the two
  main reasons for me to use ajaxtags in addition to S2.
  Any alternatives to ajaxtags?
 
  regards,
  Giovanni
 
 
  -
  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]
 
 
 

 --
 View this message in context: 
 http://www.nabble.com/about-Struts-2.0.9-portlet-example-...-tf4646784.html#a13356144
 Sent from the Struts - User mailing list archive at Nabble.com.


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



about Struts 2.0.9 portlet example ...

2007-10-18 Thread Giovanni Azua

hi all,

I managed to see the examples in the portlet webapp demo (there is no 
index page) but I didn't see any portlet anywhere ... so I am curious as 
if to there is at all an AJAX portlet control delivered with Struts 2?


Lack of portlets in S2 and AJAxification of displaytag would be the two 
main reasons for me to use ajaxtags in addition to S2.

Any alternatives to ajaxtags?

regards,
Giovanni


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



Re: about Struts 2.0.9 portlet example ...

2007-10-18 Thread Nils-Helge Garli Hegvik
Hi!

If you're thinking of the struts2-portlet application, you need to
install it into a portlet container to test it. However, ajax is not
yet built into the portlet framework.

Nils-H

On 10/18/07, Giovanni Azua [EMAIL PROTECTED] wrote:
 hi all,

 I managed to see the examples in the portlet webapp demo (there is no
 index page) but I didn't see any portlet anywhere ... so I am curious as
 if to there is at all an AJAX portlet control delivered with Struts 2?

 Lack of portlets in S2 and AJAxification of displaytag would be the two
 main reasons for me to use ajaxtags in addition to S2.
 Any alternatives to ajaxtags?

 regards,
 Giovanni


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



about struts.

2006-09-07 Thread amit fulambarkar

How can i implement connection pooling in struts. What will be the
server.xml? and what the things i would have to do.Give the code.


Re: about struts.

2006-09-07 Thread Jerome Gagner

WoW.

On 9/6/06, amit fulambarkar [EMAIL PROTECTED] wrote:

How can i implement connection pooling in struts. What will be the
server.xml? and what the things i would have to do.Give the code.




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



RE: about struts.

2006-09-07 Thread RoseIndia.net Help
Hi,

You can use apache DBCP for connection pooling. Apache DBCP is free and
robust connection pooling software.
Have a look at
http://www.roseindia.net/struts/strutsdatasourcemanagerontomcat5.shtml.
Tutorial shows you how to use DBCP with tomcat for your struts applications.

Regards
Deepak Kumar



-Original Message-
From: amit fulambarkar [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 07, 2006 12:48 PM
To: struts-user@jakarta.apache.org
Subject: about struts.


How can i implement connection pooling in struts. What will be the
server.xml? and what the things i would have to do.Give the code.


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



Re: about struts.

2006-09-07 Thread Manfred Wolff

Hi.

That's a little bit OT. The connection pool should be part of the tomcat
configuration (or an other servlet engine). The server.xml may be a good
part, better you place a xml into the
$CATALINA_HOME/conf/Catalina/localhost folder such as:

Context path=/example
 docBase=/workspaces/struts-it/examples/src/webapp
 reloadable=true
 crossContext=true

   Logger className=org.apache.catalina.logger.FileLogger
   prefix=examples_log. suffix=.txt
   timestamp=true/

   Resource name=jdbc/default
 auth=Container
 type=javax.sql.DataSource
 maxActive=100
 maxIdle=30
 maxWait=1
 username=application
 password=
 driverClassName=com.mysql.jdbc.Driver
 url=jdbc:mysql://localhost:3306/test?autoReconnect=true/

/Context

Then you are able to configure a connectionpool via jndi ressource. For
more details contact the tomcat documentation.

Manfred

Struts goes mobile. See http://www.strutsme.org




amit fulambarkar wrote:
 How can i implement connection pooling in struts. What will be the
 server.xml? and what the things i would have to do.Give the code.


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



RE: about struts.

2006-09-07 Thread Gaurav Jain
  
Add following code in server.xml to create a JNDI under context tag:-
Here is the JNDI created for oracle DB

 Resource name=jdbc/XYZ auth=SERVLET
type=oracle.jdbc.pool.OracleConnectionCacheImpl/
ResourceParams name=jdbc/XYZ
 parameter
  namefactory/name
valueorg.apache.naming.factory.BeanFactory/value
 /parameter
 parameter
  namedriverType/name
  valuethin/value
 /parameter
 parameter
  nameserverName/name
  value0.0.0.0/value
 /parameter
 parameter
  namenetworkProtocol/name
  valuetcp/value
 /parameter 
 parameter
  namedatabaseName/name
  valuexyz/value
 /parameter
 parameter
  nameportNumber/name
  value1521/value
 /parameter
 parameter
  nameuser/name
  valuexyz/value
 /parameter
 parameter
  namepassword/name
  valuea/value
 /parameter
 parameter
  namemaxLimit/name
  value5/value
 /parameter
/ResourceParams


Write the following code in  web.xml of your application
  
  !-- Example of datasources setup --
 resource-ref
descriptionOracle DataSource/description
res-ref-namejdbc/XYZ/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
  /resource-ref 

After that make the connection in action classes using this JNDI.

-Original Message-
From: amit fulambarkar [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 07, 2006 12:48 PM
To: struts-user@jakarta.apache.org
Subject: about struts.

How can i implement connection pooling in struts. What will be the
server.xml? and what the things i would have to do.Give the code.


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



RE: Question about Struts validator

2006-06-28 Thread mosho


I really appreciate all your help.

David,

I want to use struts validator and just control validation manually. Why do
I need saveErrors() method and what does it do? Isn't the validator does all
that. I am little confused.

I am pasting my execute method below, please let me know what should I add
to make it work.

The way it is wortkng now: it is giving me null pointer exception if I hit
go in the url for selstate.do action.
It is doing client site validation only if i hit submit button.

 public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response) throws
IOException, ServletException
  {
   SelStateForm sform = (SelStateForm) form;
   String isSubmitted = sform.getIsSubmitted();
   if(isSubmitted == Yes || isSubmitted.equalsIgnoreCase(Yes))
   {
   ActionErrors errors = sform.validate( mapping, request );   
if((errors != null)  errors.size()  0)
{
 return mapping.findForward(mapping.getInput()); 
}
   } 
return mapping.findForward(success);
  }
}

Wendy, thanks for letting me know about making validate false in config
file.

Thanks.
Rosh
-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a5087526
Sent from the Struts - User forum at Nabble.com.


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



RE: Question about Struts validator

2006-06-28 Thread David Friedman
Rosh,

 I want to use struts validator and just control
 validation manually. Why do I need saveErrors()
 method and what does it do? Isn't the validator
 does all that. I am little confused.

If you are going to call the validation manually, then you will have to
perform the same steps the validation framework would do.  Those steps are
normally performed in chains (or the RequestProcessor if you use and older
version) and handle a number of things automatically.  Turning the
validation off in the Struts config bypasses much of that so you will have
to do it manually.  Just calling validate gets a list of errors but does
nothing with it so it becomes lost if you do not save it somewhere.  Check
your code and you'll see you do nothing with it and it goes away when you
return your mapping.findForward().

You can learn/find out a lot more by reviewing the code from either the
source code download OR the online (http/web-based) svn repository at:
http://svn.apache.org/viewvc/struts/action/trunk/core/src/main/java/org/apac
he/struts/

 The way it is wortkng now: it is giving me null pointer
 exception if I hit go in the url for selstate.do action.

What is the stack trace?  Stack traces show what leads up to the exception
so you can figure out what class or object is having the problem.

 It is doing client site validation only if i hit submit button.

That is how it is supposed to work: client side validation invokes in the
submit but should not actually submit anything until you have cleared up all
of the client side errors.  If you are not seeing that then perhaps you
don't have the correct html:javascript formName=... tag setup properly
with the
corresponding onSubmit= for your  html:form tag.

 public ActionForward execute(ActionMapping mapping, ActionForm form,
 HttpServletRequest request, HttpServletResponse response) throws
 IOException, ServletException
  {
   SelStateForm sform = (SelStateForm) form;
   String isSubmitted = sform.getIsSubmitted();
   if(isSubmitted == Yes || isSubmitted.equalsIgnoreCase(Yes))
   {
   ActionErrors errors = sform.validate( mapping, request );
if((errors != null)  errors.size()  0)
{
 return mapping.findForward(mapping.getInput());
}
   }
return mapping.findForward(success);
  }
}

1) Isn't the method signature supposed to be (note one Exception, not two):

public ActionForward execute(ActionMapping mapping,
 ActionForm form,
 javax.servlet.http.HttpServletRequest request,
 javax.servlet.http.HttpServletResponse
response)
  throws java.lang.Exception

2) Is isSubmitted() checking some sort of variable in your page?  Why do
you have it at all?  Is this page being called a lot of times for a wizard
or something?

3) Have you put any logging statements (commons Logging Log class or even
System.out.println) anywhere so you can see/feel the flow of where you are
going and what is happening inside your action?  You know, to help you debug
this yourself?

4) See how you do nothing with the errors object so it simply goes away with
garbage collection after you return your mapping?  You need to PUT IT
somewhere to be used, hence the suggestions of using one of the various
saveErrors()/saveMessages() methods where appropriate so it doesn't
disappear with Garbage collection and you can get something meaningful out
of it which is why you are using validation to obtain/get those errors in
the first place.

Regards,
David


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



RE: Question about Struts validator

2006-06-28 Thread mosho

David,

Thanks a lot! I understood the whole concept now.
It's working perfectly!!!

Thanks again!
Rosh
-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a5089649
Sent from the Struts - User forum at Nabble.com.


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



RE: Question about Struts validator

2006-06-27 Thread mosho

Thanks David for your reply.

If I call validate method manually, can I still use validator framework and
use the input attribute in the config file to display the errors?

I need to validate only if form is submitted by clicking on a button.
If, yes can you show me with an example how to call validate method in
Action class, execute method.

Thanks
Rosh



-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a5073203
Sent from the Struts - User forum at Nabble.com.


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



Re: Question about Struts validator

2006-06-27 Thread Wendy Smoak

On 6/27/06, mosho [EMAIL PROTECTED] wrote:


If I call validate method manually, can I still use validator framework and
use the input attribute in the config file to display the errors?

I need to validate only if form is submitted by clicking on a button.
If, yes can you show me with an example how to call validate method in
Action class, execute method.


Here's a tutorial that explains how to do it:
* http://www.learntechnology.net/validate-manually.do

Another option is to override the 'validate' method of the form, and
only call super.validate() if the form was submitted.

--
Wendy

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



RE: Question about Struts validator

2006-06-27 Thread David Friedman
I'll +1 that with one reminder for Rosh:

You mentioned using the Validation Framework so don't forget to have your
ActionForm extend either ValidateActionForm or ValidatorForm.  Since I
didn't see any notes about that in Wendy's below link, and I've made this
mistake in the past, I thought I would emphasize the point for you. :)

Regards,
David

-Original Message-
From: Wendy Smoak [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 27, 2006 4:27 PM
To: Struts Users Mailing List
Subject: Re: Question about Struts validator

On 6/27/06, mosho [EMAIL PROTECTED] wrote:

 If I call validate method manually, can I still use validator framework
and
 use the input attribute in the config file to display the errors?

 I need to validate only if form is submitted by clicking on a button.
 If, yes can you show me with an example how to call validate method in
 Action class, execute method.

Here's a tutorial that explains how to do it:
 * http://www.learntechnology.net/validate-manually.do

Another option is to override the 'validate' method of the form, and
only call super.validate() if the form was submitted.

--
Wendy


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



RE: Question about Struts validator

2006-06-27 Thread mosho

Thanks David and Wendy for your help but it doesn't seem to work. 
I added manually validate in my execute method. It still validates if I
directly enter the url.

I am pasting part of my code for you to take a look and let me know where I
am going wrong. Thanks again!


--Struts config part--
action path=/selState 
type=com.sami.view.SelStateAction 
name=selStateForm
scope=session   
input=.selectState
  forward name=success path=.indianLandInfo/
/action

---SelStateAction--
SelStateForm sform = (SelStateForm) form;
   String isSubmitted = sform.getIsSubmitted();
   if(isSubmitted == Yes || isSubmitted.equalsIgnoreCase(Yes))
   {
   ActionErrors errors = sform.validate( mapping, request );  
   }   
  
return mapping.findForward(success);

---JSP file---

html:form action=selState.do method=POST onsubmit=return
validateSelStateForm(this);
 .
.
 html:hidden property=isSubmitted value=yes /
/table
html:javascript formName=selStateForm /
/html:form
-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a5074217
Sent from the Struts - User forum at Nabble.com.


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



RE: Question about Struts validator

2006-06-27 Thread mosho

Thanks David and Wendy for your help but it doesn't seem to work.
I added manually validate in my execute method. It still validates if I
directly enter the url.

I am pasting part of my code for you to take a look and let me know where I
am going wrong. Thanks again!


--Struts config part--
action path=/selState
type=com.sami.view.SelStateAction
name=selStateForm
scope=session  
input=.selectState
  forward name=success path=.indianLandInfo/
/action

---SelStateAction--
SelStateForm sform = (SelStateForm) form;
   String isSubmitted = sform.getIsSubmitted();
   if(isSubmitted == Yes || isSubmitted.equalsIgnoreCase(Yes))
   {
   ActionErrors errors = sform.validate( mapping, request );  
   }  
 
return mapping.findForward(success);

---JSP file---

html:form action=selState.do method=POST onsubmit=return
validateSelStateForm(this);
 .
.
 html:hidden property=isSubmitted value=yes /
/table
html:javascript formName=selStateForm /
/html:form
-- 
View this message in context: 
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a5074256
Sent from the Struts - User forum at Nabble.com.


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



Re: Question about Struts validator

2006-06-27 Thread Wendy Smoak

On 6/27/06, mosho [EMAIL PROTECTED] wrote:


Thanks David and Wendy for your help but it doesn't seem to work.
I added manually validate in my execute method. It still validates if I
directly enter the url.

...

--Struts config part--
action path=/selState
type=com.sami.view.SelStateAction
name=selStateForm
scope=session
input=.selectState
  forward name=success path=.indianLandInfo/
/action


You need to set validate=false in the action mapping.  The default
is true, which is the behavior you're seeing.

--
Wendy

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



RE: Question about Struts validator

2006-06-27 Thread David Friedman
Rosh,

1. Were any errors produced?  You never check.  Perhaps:
(errors != null)  errors.size()  0

2. Do you save the errors with a method such as saveMessages() /
saveErrors() ?   How are you going to get them to your html:form so you can
show them to the client with html:errors, html:messages, etc.

3. Do you go anywhere if you FIND errors?  No.  Your code snippet ALWAYS
returns to your success mapping.  If you find errors you might want to go
the input mapping or one of your own choosing.  I think the input mapping
might be jumped to by something like this:

return mapping.findForward(mapping.getInput());

I might have typed incorrectly but you can probably get the idea of what I
am suggesting from that code suggestion above.

4. Where in your example JSP do you show your errors if any occur?  See the
section from the html: taglib on html:errors at:
http://struts.apache.org/struts-action/struts-taglib/apidocs/org/apache/stru
ts/taglib/html/package-summary.html#doc.Other.errors
Though I thought it was html:messages now.  I must be using an older version
but the rest should apply.  *shrug*

Much of this is listed in Wendy's example.  I recommend you review it again
before you consider my suggestions so you can see how my suggestions mirror
much of what is shown in her examples.

Regards,
David

-Original Message-
From: mosho [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 27, 2006 5:18 PM
To: user@struts.apache.org
Subject: RE: Question about Struts validator



Thanks David and Wendy for your help but it doesn't seem to work.
I added manually validate in my execute method. It still validates if I
directly enter the url.

I am pasting part of my code for you to take a look and let me know where I
am going wrong. Thanks again!


--Struts config part--
action path=/selState
type=com.sami.view.SelStateAction
name=selStateForm
scope=session
input=.selectState
  forward name=success path=.indianLandInfo/
/action

---SelStateAction--
SelStateForm sform = (SelStateForm) form;
   String isSubmitted = sform.getIsSubmitted();
   if(isSubmitted == Yes || isSubmitted.equalsIgnoreCase(Yes))
   {
   ActionErrors errors = sform.validate( mapping, request );
   }

return mapping.findForward(success);

---JSP file---

html:form action=selState.do method=POST onsubmit=return
validateSelStateForm(this);
 .
.
 html:hidden property=isSubmitted value=yes /
/table
html:javascript formName=selStateForm /
/html:form
--
View this message in context:
http://www.nabble.com/Question-about-Struts-validator-tf1851247.html#a507421
7
Sent from the Struts - User forum at Nabble.com.


-
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: about struts latest version

2006-02-16 Thread Gary Feidt
Please go to: http://struts.apache.org/ 

 [EMAIL PROTECTED] 2/15/2006 11:22:53 PM 


Hi
what is the latest version of struts.what are the new features added to
this

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

Confidentiality Statement:
This email/fax, including attachments, may include confidential and/or 
proprietary information and may be used only by the person or entity to which 
it is addressed. If the reader of this email/fax is not the intended recipient 
or his or her agent, the reader is hereby notified that any dissemination, 
distribution or copying of this email/fax is prohibited. If you have received 
this email/fax in error, please notify the sender by replying to this message 
and deleting this email or destroying this facsimile immediately.

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



about struts latest version

2006-02-15 Thread gomathi


Hi
what is the latest version of struts.what are the new features added to this

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



About Struts

2006-01-30 Thread Naveen Sharma
I am a beginner at struts.
Can u plz tell me the basics of Struts


Doubts about Struts-layout

2005-12-21 Thread Sony Thomas

Hi friends,

Is struts layout is a dependable library to use. I am finding many 
difficulties to implement it. so is it a reliable one to use ?



sony

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



question about Struts html tags and Javascript getElementById

2005-08-22 Thread Gordon Hu
I am having difficulties referencing struts html tags through Javacript.
I am trying to validate 10 file upload boxes to see if the user has at least 
uploaded 1 file and also to validate the extension of the file (.jpg).
  trhtml:file name=uploadFilesActionForm property=uploadedFiles[0] 
accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[1] 
accept=image/jpg, image/jpeg /html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[2] 
accept=image/jpg, image/jpeg /html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[3] 
accept=image/jpg, image/jpeg /html:file/tr
..and so on
 I am trying to set up a Javascript function like the following:
 document.form.getElementById(uploadedFiles);
 But it does not work.
Any ideas?


Re: question about Struts html tags and Javascript getElementById

2005-08-22 Thread Dave Newton

Gordon Hu wrote:

 trhtml:file name=uploadFilesActionForm property=uploadedFiles[0] 
accept=image/jpg, image/jpeg/html:file/tr

I am trying to set up a Javascript function like the following:
document.form.getElementById(uploadedFiles);
Any ideas?
 


What does the generated file upload HTML look like if you view source?

Dave




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



Re: question about Struts html tags and Javascript getElementById

2005-08-22 Thread Gordon Hu
trinput type=file name=uploadedFiles[0] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[1] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[2] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[3] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[4] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[5] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[6] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[7] accept=image/jpg, 
image/jpeg value=/tr
trinput type=file name=uploadedFiles[8] accept=image/jpg, 
image/jpeg value=/tr

On 8/22/05, Dave Newton [EMAIL PROTECTED] wrote: 
 
 Gordon Hu wrote:
 
  trhtml:file name=uploadFilesActionForm property=uploadedFiles[0]
 accept=image/jpg, image/jpeg/html:file/tr
  I am trying to set up a Javascript function like the following:
  document.form.getElementById(uploadedFiles);
 Any ideas?
 
 
 What does the generated file upload HTML look like if you view source?
 
 Dave
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



Re: question about Struts html tags and Javascript getElementById

2005-08-22 Thread Dave Newton

Gordon Hu wrote:

trinput type=file name=uploadedFiles[0] accept=image/jpg, 
image/jpeg value=/tr
 

I was asking as a subtle hint that there is nothing with an id of 
uploadedFiles making your JavaScript not do what you want it to.


On 8/22/05, Dave Newton [EMAIL PROTECTED] wrote: 
 


Gordon Hu wrote:
   


trhtml:file name=uploadFilesActionForm property=uploadedFiles[0]
accept=image/jpg, image/jpeg/html:file/tr
I am trying to set up a Javascript function like the following:
document.form.getElementById(uploadedFiles);
Any ideas?


What does the generated file upload HTML look like if you view source?
   





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



Re: question about Struts html tags and Javascript getElementById

2005-08-22 Thread Ross Gibb
According to the docs, 
http://struts.apache.org/userGuide/struts-html.html#file, the html:file 
tag will render and id tag with the attribute styleId.  Also, when I use 
getElementById I just call it on the document.  So what I think you are 
trying to do is so:


trhtml:file name=uploadFilesActionForm property=uploadedFiles[0] 
styleId=uploadedFiles1 accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[1] 
styleId=uploadedFiles2 accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[2] 
styleId=uploadedFiles3 accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[3] 
styleId=uploadedFiles4 accept=image/jpg, image/jpeg/html:file/tr


In javascript you should be able to get a reference to those nodes by 
calling document.getElementById(uploadedFiles1), for example.


That being said, what I showed you is not the way I would do it. Also, 
your property attributes look funny to me. I would do this.


trhtml:file name=uploadFilesActionForm property=uploadedFiles 
accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles 
accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles 
accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles 
accept=image/jpg, image/jpeg/html:file/tr


(I think you'll want td/td surrounding the html:files, I omitted 
them for space).


Even without the id attribute you can still easily get a reference to 
these nodes in javascript


You could call a javascript function when the form submits, i.e. 
html:submit onclick=return verify(this.form);/. In the javascript 
you could get the reference to the html:file nodes like so:


function verify(form){
   /* this will return an array of the html:file nodes with 
property=uploadedFiles */

   var fileInputs = form['uploadedFiles'];
}

Some of my syntax could be wrong, but the jist of it should be correct.

Ross



Gordon Hu wrote:


I am having difficulties referencing struts html tags through Javacript.
I am trying to validate 10 file upload boxes to see if the user has at least 
uploaded 1 file and also to validate the extension of the file (.jpg).
 trhtml:file name=uploadFilesActionForm property=uploadedFiles[0] 
accept=image/jpg, image/jpeg/html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[1] 
accept=image/jpg, image/jpeg /html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[2] 
accept=image/jpg, image/jpeg /html:file/tr
trhtml:file name=uploadFilesActionForm property=uploadedFiles[3] 
accept=image/jpg, image/jpeg /html:file/tr

..and so on
I am trying to set up a Javascript function like the following:
document.form.getElementById(uploadedFiles);
But it does not work.
Any ideas?

 



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



Re: question about Struts html tags and Javascript getElementById

2005-08-22 Thread Sudhaker Raj
This works in IE, Hope this helps. Thanks.

form name=myForm onsubmit=return checkMe(this);

trinput type=file name=uploadedFiles[0] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[1] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[2] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[3] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[4] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[5] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[6] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[7] accept=image/jpg,
image/jpeg value=/tr
trinput type=file name=uploadedFiles[8] accept=image/jpg,
image/jpeg value=/tr

input type=submit/

/form

script
var checkMe = function(thisForm) {
alert(thisForm.elements['uploadedFiles[0]'].value);
return false;
};
/script


On 8/22/05, Dave Newton [EMAIL PROTECTED] wrote:
 Gordon Hu wrote:
 
 trinput type=file name=uploadedFiles[0] accept=image/jpg,
 image/jpeg value=/tr
 
 
 I was asking as a subtle hint that there is nothing with an id of
 uploadedFiles making your JavaScript not do what you want it to.
 
 On 8/22/05, Dave Newton [EMAIL PROTECTED] wrote:
 
 
 Gordon Hu wrote:
 
 
 trhtml:file name=uploadFilesActionForm property=uploadedFiles[0]
 accept=image/jpg, image/jpeg/html:file/tr
 I am trying to set up a Javascript function like the following:
 document.form.getElementById(uploadedFiles);
 Any ideas?
 
 What does the generated file upload HTML look like if you view source?
 
 
 
 
 
 -
 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: Opinion about Struts layout

2005-08-02 Thread Borislav Sabev

starki78 wrote:


Do you think this framework is stable and good?
I have tested it and my first impression is not bad.
Is there someone who uses it for its purposes?

Ciao Christian


 


Hi Christian,

I use struts-layout from 4-5 months, and it saves a lot of develompent time.
One of the best features (IMHO) is the forms mode - a form can be 
shown in different modes like READ_ONLY, WRITE etc. the same is applied 
for the controls in the forms
The end effect of this is that you write only one jsp for presenting and 
editing.

The collections tags are also very nice

It's not perfect, but it's much more usefull than plain struts tags. At 
least my jsp incude very small amount of java code and plain HTML tags.


Regards
Borislav


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



Re: Opinion about Struts layout

2005-08-02 Thread starki78
thanks Borislav for your answer!


-- Initial Header ---

From  : Borislav Sabev [EMAIL PROTECTED]
To  : Struts Users Mailing List user@struts.apache.org
Cc  :
Date  : Tue, 02 Aug 2005 09:01:46 +0200
Subject : Re: Opinion about Struts layout







 starki78 wrote:

 Do you think this framework is stable and good?
 I have tested it and my first impression is not bad.
 Is there someone who uses it for its purposes?
 
 Ciao Christian
 
 
 
 
 Hi Christian,

 I use struts-layout from 4-5 months, and it saves a lot of develompent time.
 One of the best features (IMHO) is the forms mode - a form can be
 shown in different modes like READ_ONLY, WRITE etc. the same is applied
 for the controls in the forms
 The end effect of this is that you write only one jsp for presenting and
 editing.
 The collections tags are also very nice

 It's not perfect, but it's much more usefull than plain struts tags. At
 least my jsp incude very small amount of java code and plain HTML tags.

 Regards
 Borislav


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

 




6X velocizzare la tua navigazione a 56k? 6X Web Accelerator di Libero!
Scaricalo su INTERNET GRATIS 6X http://www.libero.it



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



Re: Opinion about Struts layout

2005-08-02 Thread Borislav Sabev

starki78 wrote:


thanks Borislav for your answer!


 



I can provide you some screenshots from 2 applications that I work on - 
they are not finished, but may be can give you some ideas about the 
power of struts-layout.
And I have a friend who did some miracles with struts-layout, but he 
re-wrote big part of the tags and made his own renders.
So depends what youd' like to achieve, depends how big is your 
application and how much do you want to invest in your own tags and tools.


Borislav


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



Re: Opinion about Struts layout

2005-08-02 Thread starki78
Hi Boris,

thank you very much for your offer. Certainly
you can send me a link or screenshots my mail is
[EMAIL PROTECTED]
Currently we are in an evalution phase...

Have a nice day
Saluti Starki


 starki78 wrote:

 thanks Borislav for your answer!
 
 
 
 

 I can provide you some screenshots from 2 applications that I work on -
 they are not finished, but may be can give you some ideas about the
 power of struts-layout.
 And I have a friend who did some miracles with struts-layout, but he
 re-wrote big part of the tags and made his own renders.
 So depends what youd' like to achieve, depends how big is your
 application and how much do you want to invest in your own tags and tools.

 Borislav


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

 




Libero Flat, sempre a 4 Mega a 19,95 euro al mese! 
Abbonati subito su http://www.libero.it




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



Opinion about Struts layout

2005-08-01 Thread starki78
Do you think this framework is stable and good?
I have tested it and my first impression is not bad.
Is there someone who uses it for its purposes?

Ciao Christian




Libero Flat, sempre a 4 Mega a 19,95 euro al mese! 
Abbonati subito su http://www.libero.it




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



RE: [OT] Survey - Tell me what you think about Struts.

2005-05-02 Thread Barnett, Brian W.
I addressed the stuffing up of any useful CVS functionality by using
Jalopy source code formatter. http://jalopy.sourceforge.net. The key is for
someone to specify the source code formatting rules, usually the defaults
are close enough for most. Jalopy provides export functionality, so all
you have to do is export the settings and distribute the export file to all
of your developers. Run Jalopy on the files before you commit them to CVS
and your problem is resolved.

Brian Barnett

-Original Message-
From: Adam Hardy [mailto:[EMAIL PROTECTED] 
Sent: Sunday, May 01, 2005 2:28 PM
To: Struts Users Mailing List
Subject: Re: [OT] Survey - Tell me what you think about Struts.


On 01/05/05 13:13nbsp;Simon Chappell wrote:
What is it that bugs you the most about development with Struts?
 
 Trying to work with the struts-config.xml without a dedicated editor. 
 I have a small, three actions, project that I'm tinkering with and I 
 figured that it was small enough that I didn't need to worry and I 
 could just edit struts-config.xml using a text editor. Ouch.

Dedicated editors are a bane for me. The fact that they automatically 
format the whole file according to their xml whitespace, indenting and 
new line rules means that every line can change when a 2nd developer 
edits the file, which really stuffs up any useful CVS functionality.

My biggest issue with struts is the large number of obtuse servlet 
exceptions or plain empty pages that newbies can cause by doing 
something wrong.

Linked to that is the large amount of definitions in xml where the 
correctness is uncheckable until runtime. One silly typo and I have to 
compile, deploy, restart and navigate into the app to check it works. 
Perhaps there's some junit testing I should be doing to check it all in 
one click, but I haven't worked it out yet.

Adam

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

 
This email may contain confidential material. 
If you were not an intended recipient, 
Please notify the sender and delete all copies. 
We may monitor email to and from our network. 


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



Re: [OT] Survey - Tell me what you think about Struts.

2005-05-01 Thread Simon Chappell
James,

Here's a couple:

 What is it that bugs you the most about development with Struts?

Trying to work with the struts-config.xml without a dedicated editor.
I have a small, three actions, project that I'm tinkering with and I
figured that it was small enough that I didn't need to worry and I
could just edit struts-config.xml using a text editor. Ouch.

Also, it's good that Struts is so configurable, but with everything in
one file it gets unworkable sooner rather than later.

Also, be careful to keep your business logic out of your actions and
keep your servlet context out of your business logic. This is not
really Strut's fault, but it's still a good warning for newbies.

 On the plus side, if you have a success story you are dying to tell.  I'd
 love to hear about it.

I'm sure people are fed up of me bragging on the project I did at
Lands' End, so I won't say too much, except that Struts rocks and is
suitable for large projects and is gracefully handling some very close
to real-time kind of response times.

Simon

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



Re: [OT] Survey - Tell me what you think about Struts.

2005-05-01 Thread Adam Hardy
On 01/05/05 13:13nbsp;Simon Chappell wrote:
What is it that bugs you the most about development with Struts?
Trying to work with the struts-config.xml without a dedicated editor.
I have a small, three actions, project that I'm tinkering with and I
figured that it was small enough that I didn't need to worry and I
could just edit struts-config.xml using a text editor. Ouch.
Dedicated editors are a bane for me. The fact that they automatically 
format the whole file according to their xml whitespace, indenting and 
new line rules means that every line can change when a 2nd developer 
edits the file, which really stuffs up any useful CVS functionality.

My biggest issue with struts is the large number of obtuse servlet 
exceptions or plain empty pages that newbies can cause by doing 
something wrong.

Linked to that is the large amount of definitions in xml where the 
correctness is uncheckable until runtime. One silly typo and I have to 
compile, deploy, restart and navigate into the app to check it works. 
Perhaps there's some junit testing I should be doing to check it all in 
one click, but I haven't worked it out yet.

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


[OT] Survey - Tell me what you think about Struts.

2005-04-30 Thread James Mitchell
I'll be speaking at a developer conference this month and as an addition to 
the current outline, I would like to put together a list of common pitfalls 
(with respect to development with Struts) that developers find themselves 
battling on a daily basis.  Is it misconfiguration?  Is it constantly having 
to restart your container?  What is it that bugs you the most about 
development with Struts?

On the plus side, if you have a success story you are dying to tell.  I'd 
love to hear about it.


--
James Mitchell
Software Engineer / Open Source Evangelist
Consulting / Mentoring / Freelance
EdgeTech, Inc.
678.910.8017
AIM:   jmitchtx
Yahoo: jmitchtx
MSN:   [EMAIL PROTECTED]


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


I must be missing something fundamental about Struts ...

2005-01-08 Thread Mark McWiggins
... as I seem to get stuck on the simplest things.
For example:
I have set up Eclipse with MyEclipse (thanks, Jim Barrows, for this 
recommendation)
and just trying to get simple page flow working. But I don't seem to 
understand 'forwards',
as I have a 2-line index.jsp:

   %@ taglib uri=http://jakarta.apache.org/struts/tags-logic; 
prefix=logic %
   logic:redirect forward=welcome/

that seems to work but then a forward from that page,  Welcome.jsp:
   %@ page language=java%
   %@ taglib uri=http://jakarta.apache.org/struts/tags-bean; 
prefix=bean %
   %@ taglib uri=http://jakarta.apache.org/struts/tags-html; 
prefix=html %
   %@ taglib uri=http://jakarta.apache.org/struts/tags-logic; 
prefix=logic %
   %@ taglib uri=http://jakarta.apache.org/struts/tags-tiles; 
prefix=tiles %
   %@ taglib uri=http://jakarta.apache.org/struts/tags-template; 
prefix=template %
   %@ taglib uri=http://jakarta.apache.org/struts/tags-nested; 
prefix=nested %

   !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
   html:html
 head
   html:base /
  
   titleWelcome to eTracICR/title
  
   meta http-equiv=pragma content=no-cache
   meta http-equiv=cache-control content=no-cache
   meta http-equiv=expires content=0   
   meta http-equiv=keywords content=keyword1,keyword2,keyword3
   meta http-equiv=description content=This is my page
 /head

 body
   html:link forward=signonSign in/html:link br
 /body
   /html:html
Tomcat gives this error:
javax.servlet.ServletException: Cannot create rewrite URL: 
java.net.MalformedURLException: Cannot retrieve ActionForward named signon
Even though I am looking at a global forward and a local forward named 
'signon', and an 'actionMapping' to
match, it looks to me, all approved by MyEclipse so I am at least not making 
any dumb XML syntax errors:
?xml version=1.0 encoding=UTF-8?
!DOCTYPE struts-config PUBLIC -//Apache Software Foundation//DTD Struts Configuration 
1.1//EN http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd;
struts-config
   data-sources /
   form-beans 
  form-bean name=signonForm type=app.SignonForm /
   /form-beans
	   global-exceptions /
	   global-forwards 
	  forward name=welcome path=/Welcome.do /
 
 
 		forward name=signon path=/SignOn.do /

   /global-forwards
   action-mappings 
  action
 parameter=/Welcome.jsp
 path=/Welcome
 type=org.apache.struts.actions.ForwardAction 
 forward name=signon path=/SignOn.do /
  /action
  action
 attribute=signonForm
 input=/SignOn.jsp
 name=signonForm
 path=/SignonSubmit
 scope=request
 type=app.SignonAction /
  action
 parameter=/SignOn.jsp
 path=/SignOn
 type=org.apache.struts.actions.ForwardAction
 forward name=success path=/Yay.jsp /
 forward name=failure path=/Rats.jsp /
  /action
   /action-mappings
   message-resources 
parameter=com.yourcompany.struts.ApplicationResources /
/struts-config
I have looked at this until I am even more crosseyed than normal :-), so if 
it's obvious
to you at a glance what's going on I would be very grateful for a slap up 'side 
the head!
Thanks,
Mark McWiggins
425-369-8286


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


Re: I must be missing something fundamental about Struts ...

2005-01-08 Thread Curtis Taylor
Hi Mark,
Try changing the 'forward' to 'action' in your html:link tag:
html:link action=signonSign in/html:link
HTH,
Curtis
Mark McWiggins wrote:
... as I seem to get stuck on the simplest things.
For example:
 body
   html:link forward=signonSign in/html:link br
 /body
Thanks,
Mark McWiggins
425-369-8286

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


my testimony about Struts

2004-12-13 Thread t t
No question. Struts is a wonderful tool to build websites. I just built one: 
www.sportslovers.net using Struts.
Take a look if you are a sports lover or you are a web developer but still 
doubt Struts.
Sorry if this post bothered you.


 

-
Do you Yahoo!?
 Send a seasonal email greeting and help others. Do good.

Re: my testimony about Struts

2004-12-13 Thread James Mitchell
Looks good T!

--
James Mitchell
Software Engineer / Open Source Evangelist
EdgeTech, Inc.
678.910.8017
AIM: jmitchtx
- Original Message - 
From: t t [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Monday, December 13, 2004 11:27 AM
Subject: my testimony about Struts


No question. Struts is a wonderful tool to build websites. I just built 
one: www.sportslovers.net using Struts.
Take a look if you are a sports lover or you are a web developer but still 
doubt Struts.
Sorry if this post bothered you.


-
Do you Yahoo!?
Send a seasonal email greeting and help others. Do good. 

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


Re: my testimony about Struts

2004-12-13 Thread t t
Thanks, James.

James Mitchell [EMAIL PROTECTED] wrote:Looks good T!



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

- Original Message - 
From: t t 
To: Struts Users Mailing List 
Sent: Monday, December 13, 2004 11:27 AM
Subject: my testimony about Struts


 No question. Struts is a wonderful tool to build websites. I just built 
 one: www.sportslovers.net using Struts.
 Take a look if you are a sports lover or you are a web developer but still 
 doubt Struts.
 Sorry if this post bothered you.




 -
 Do you Yahoo!?
 Send a seasonal email greeting and help others. Do good. 



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




-
Do you Yahoo!?
 Yahoo! Mail - Easier than ever with enhanced search. Learn more.

Q's about Struts release information and upgrade guides

2004-11-18 Thread David G. Friedman
Where are the release notes for Struts versions before 1.2.4?  I just
received a question about code changes (via a private email) and cannot find
the changes from v1.0 to 1.2.4 on the Strut site or the Wiki (not where I
looked anyway). I would have expected to have found this information on the
release notes but it only lists the nightly 1.2.5 build and a 1.2.6
development build.  Can a link be made on
http://struts.apache.org/userGuide/release-notes.html to a page listing
changes/deprecations/etc. for previous versions for those who need to
upgrade?  I'd hate to have people emailing the list because they jumped
from, say v1.0 to v1.2.4 and BOOM big unexplainable compilations breaks
occur.  After all, so many things were deprecated AND removed from the code
but the reasons are no longer listed (where I looked).

Thank and regards,
David


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



good book about struts

2004-10-05 Thread Ye, Young
Hi Struters,

I am working in a project which use struts. I would like to buy a book about
struts. But there are many of them in the market. Can you recommend the one
which you think is best? 

Thanks a lot


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



RE: good book about struts

2004-10-05 Thread Robin Mannering
Hi,

Can't say which is best as I have only read Struts in Action: Ted Husted.

I find it invaluable as a reference and very easy to read ! I recommend it.  Nice 
extra chapters too, especially the chapter on replacing JSPs with Velocity 
templates

Robin

-Original Message-
From: Ye, Young [mailto:[EMAIL PROTECTED]
Sent: 05 October 2004 16:39
To: 'Struts Users Mailing List'
Subject: good book about struts


Hi Struters,

I am working in a project which use struts. I would like to buy a book about
struts. But there are many of them in the market. Can you recommend the one
which you think is best? 

Thanks a lot


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



This e-mail and any attachments may be confidential and/or legally
privileged. If you have received this e-mail and you are not a named
addressee, please inform Landmark Information Group on 01491 413030
and then delete the e-mail from your system. If you are not a named
addressee you must not use, disclose, distribute, copy, print or rely 
on this e-mail. This email and any attachments have been scanned for
viruses and to the best of our knowledge are clean. To ensure 
regulatory compliance and for the protection of our clients and 
business, we may monitor and read e-mails sent to and from our 
servers.


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



RE: good book about struts

2004-10-05 Thread Ricardo Andres Quintero
How much u know about Struts?
I read programming Jakarta Struts of chuck Cavaness, OReally.
It is a very very nice book if u dont know anything about Struts.


On Tue, 5 Oct 2004 16:45:44 +0100, Robin Mannering wrote
 Hi,
 
 Can't say which is best as I have only read Struts in Action: Ted 
 Husted.
 
 I find it invaluable as a reference and very easy to read ! I 
 recommend it.  Nice extra chapters too, especially the chapter on 
 replacing JSPs with Velocity templates
 
 Robin
 
 -Original Message-
 From: Ye, Young [mailto:[EMAIL PROTECTED]
 Sent: 05 October 2004 16:39
 To: 'Struts Users Mailing List'
 Subject: good book about struts
 
 Hi Struters,
 
 I am working in a project which use struts. I would like to buy a 
 book about
 struts. But there are many of them in the market. Can 
 you recommend the one
 which you think is best? 
 
 Thanks a lot
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 This e-mail and any attachments may be confidential and/or legally
 privileged. If you have received this e-mail and you are not a named
 addressee, please inform Landmark Information Group on 01491 413030
 and then delete the e-mail from your system. If you are not a named
 addressee you must not use, disclose, distribute, copy, print or 
 rely on this e-mail. This email and any attachments have been 
 scanned for viruses and to the best of our knowledge are clean. To 
 ensure regulatory compliance and for the protection of our clients 
 and business, we may monitor and read e-mails sent to and from our servers.
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


--
Ricardo Andrés Quintero R.
Ubiquando Ltda.


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



Re: good book about struts

2004-10-05 Thread Robert Barksdale
+1 for Ted Husted's Struts in Action


On Tue, 5 Oct 2004 10:48:41 -0400, Ricardo Andres Quintero
[EMAIL PROTECTED] wrote:
 How much u know about Struts?
 I read programming Jakarta Struts of chuck Cavaness, OReally.
 It is a very very nice book if u dont know anything about Struts.
 
 On Tue, 5 Oct 2004 16:45:44 +0100, Robin Mannering wrote
 
 
  Hi,
 
  Can't say which is best as I have only read Struts in Action: Ted
  Husted.
 
  I find it invaluable as a reference and very easy to read ! I
  recommend it.  Nice extra chapters too, especially the chapter on
  replacing JSPs with Velocity templates
 
  Robin
 
  -Original Message-
  From: Ye, Young [mailto:[EMAIL PROTECTED]
  Sent: 05 October 2004 16:39
  To: 'Struts Users Mailing List'
  Subject: good book about struts
 
  Hi Struters,
 
  I am working in a project which use struts. I would like to buy a
  book about
  struts. But there are many of them in the market. Can
  you recommend the one
  which you think is best?
 
  Thanks a lot
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
  
  This e-mail and any attachments may be confidential and/or legally
  privileged. If you have received this e-mail and you are not a named
  addressee, please inform Landmark Information Group on 01491 413030
  and then delete the e-mail from your system. If you are not a named
  addressee you must not use, disclose, distribute, copy, print or
  rely on this e-mail. This email and any attachments have been
  scanned for viruses and to the best of our knowledge are clean. To
  ensure regulatory compliance and for the protection of our clients
  and business, we may monitor and read e-mails sent to and from our servers.
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 --
 Ricardo Andrés Quintero R.
 Ubiquando Ltda.
 
 
 
 
 -
 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]



Question about Struts ActionForm scope and clustering

2004-09-29 Thread Wong, Cindy
All,

 

I'm not sure if I am contacting the right list but this is the problem
that I am facing:

I am trying to convert a series of registration pages over to Struts.
The web server that I am using is JBoss 3.2 and it will eventually be
implemented on a cluster. What I want to know is what the scope=session
in an ActionForm refers to. Is this the HTTP session or is it some other
internal session that only Struts use? If I create only one ActionForm
for all the registration pages and set them all to use the same
ActionForm with the ActionForm's scope set to session, does this mean
that the information in the ActionForm is saved for the next
registration page that the registration process hits? If it does, how
does this work in a cluster?

 

 

 

 

Cindy Wong

 



Re: Question about Struts ActionForm scope and clustering

2004-09-29 Thread brenmcguire
When you declare that a form-bean connected to an action is used with
scope session means that an instance of that form bean will be put
inside the session space, i.e. the one you take calling:
request.getSession()
Then, the form bean is put inside the session scope of the web server that
interacts with the client. The connection between the saved form bean and
the client is made using session cookies (if enabled) or the URL rewriting
(with the jsessionid additional parameter in the URL), both managed by
Struts.
For your case, form beans in session scope have nothing to do with
clustering, because they are saved only in one place (the web server) and
if you want to let know its value to other places you need to propagate
the form bean itself or at least its values.
Hope it helps
Ciao
Antonio Petrelli


 All,



 I'm not sure if I am contacting the right list but this is the problem
 that I am facing:

 I am trying to convert a series of registration pages over to Struts.
 The web server that I am using is JBoss 3.2 and it will eventually be
 implemented on a cluster. What I want to know is what the scope=session
 in an ActionForm refers to. Is this the HTTP session or is it some other
 internal session that only Struts use? If I create only one ActionForm
 for all the registration pages and set them all to use the same
 ActionForm with the ActionForm's scope set to session, does this mean
 that the information in the ActionForm is saved for the next
 registration page that the registration process hits? If it does, how
 does this work in a cluster?









 Cindy Wong







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



philosophical question/poll about Struts/JSTL, scriptlets

2004-08-27 Thread Woodchuck
sorry to bring this up on a Friday...

does everyone here have pure Struts/JSTL jsp pages that is absolutely
void of scriptlets?

or do you have jsp pages that use a combination of Struts/JSTL and
scriptlets, all living together harmoniously using whichever method is
easiest/cleanest?

is mixing Struts/JSTL with traditional scriptlets a bad thing?

i have to say that i would prefer to *not* mix scriptlets with
Struts/JSTL but in some situations it seems scriptlets is the better
solution (in terms of code maintainability).  that is, it would be
easier to use a little snippet of scriptlet here and there instead of
making a round-about (albeit clever) and more verbose way of doing the
same thing without scriptlets...

any opinions is welcome!  i want to be able to sleep without nightmares
about this!!  :)





__
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.
http://mobile.yahoo.com/maildemo 

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



RE: philosophical question/poll about Struts/JSTL, scriptlets

2004-08-27 Thread Jim Barrows


 -Original Message-
 From: Woodchuck [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 27, 2004 10:22 AM
 To: struts
 Subject: philosophical question/poll about Struts/JSTL, scriptlets
 
 
 sorry to bring this up on a Friday...
 
 does everyone here have pure Struts/JSTL jsp pages that is absolutely
 void of scriptlets?

Every single one but the main layout page, because I haven't figured out a better way 
to use tiles putList.
I avoid them like the plague they're almost, imho, as bad as javascript.  Then 
again I have nightmares about out.println(html)...

 
 or do you have jsp pages that use a combination of Struts/JSTL and
 scriptlets, all living together harmoniously using whichever method is
 easiest/cleanest?

Depends.. I turn everything over to a html person.  The lesss scriptlets I use the 
happier she is.


 
 is mixing Struts/JSTL with traditional scriptlets a bad thing?

I thinks so... ymmmv

 
 i have to say that i would prefer to *not* mix scriptlets with
 Struts/JSTL but in some situations it seems scriptlets is the better
 solution (in terms of code maintainability).  that is, it would be
 easier to use a little snippet of scriptlet here and there instead of
 making a round-about (albeit clever) and more verbose way of doing the
 same thing without scriptlets...

Depends on what you're talking about.. and who you're talking about.  If your code is 
never going to be seen by anybody but java programmers,then you may be correct.

 
 any opinions is welcome!  i want to be able to sleep without 
 nightmares
 about this!!  :)

Most programmers would probably find that the scriptlets are somewhat easier...however 
I also look at tags as method calls, in terms of encapsulation.   I don't need to know 
what they do, just that they do it.  I don't really care how html:radio generates a 
radio html bit, just that it does so in a manner that makes my life easier, like only 
having to know the property name etc. etc.
I have several tags that print lists of things change the tag and I've changed the 
way the lists are retrieved.  That can be harder to do in a scriptlet.
Using scriptlets, to me is like going back to the bad old days of 
out.println(html);.



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



RE: philosophical question/poll about Struts/JSTL, scriptlets

2004-08-27 Thread Daniel Perry
hah forget the 'purist' approach!

I use jstl / struts taglibs whereever possible.

if i had a choice between writing my on taglib or scriptlet for me
scriptlet wins - much less hassel, and the code is there for you on the jsp,
and it's only normally for very simple things.

The main times i use scriptlets are for stupidly simple things that appear
to have been overlooked with el/jstl:

% pageContext.setAttribute(linefeed, \n); %

Because you cant use \n in el for search and replace strings.

Other use is for copying static final variables to the page context (how no
one spotted this before el was finalised i will never know? or am i missing
somthing?)

Daniel.

 -Original Message-
 From: Woodchuck [mailto:[EMAIL PROTECTED]
 Sent: 27 August 2004 18:22
 To: struts
 Subject: philosophical question/poll about Struts/JSTL, scriptlets


 sorry to bring this up on a Friday...

 does everyone here have pure Struts/JSTL jsp pages that is absolutely
 void of scriptlets?

 or do you have jsp pages that use a combination of Struts/JSTL and
 scriptlets, all living together harmoniously using whichever method is
 easiest/cleanest?

 is mixing Struts/JSTL with traditional scriptlets a bad thing?

 i have to say that i would prefer to *not* mix scriptlets with
 Struts/JSTL but in some situations it seems scriptlets is the better
 solution (in terms of code maintainability).  that is, it would be
 easier to use a little snippet of scriptlet here and there instead of
 making a round-about (albeit clever) and more verbose way of doing the
 same thing without scriptlets...

 any opinions is welcome!  i want to be able to sleep without nightmares
 about this!!  :)





 __
 Do you Yahoo!?
 Take Yahoo! Mail with you! Get it on your mobile phone.
 http://mobile.yahoo.com/maildemo

 -
 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: philosophical question/poll about Struts/JSTL, scriptlets

2004-08-27 Thread Daniel Perry
 Using scriptlets, to me is like going back to the bad old days of
 out.println(html);.

Over the last two weeks, i had to do a major refactoring of an application.
This involved spiltting a person class down into person and profile, and
everything that was linked to person now linking to profile.

It took me a day or so to fix the java code, but the jsps took forever!

During this process i was thinking about how much easier it would be in i
was doing html using out.println(html);!!!

The reason for this, is using pure java, once the app is broken (put the new
class in, and change references in the beans) it's easy to go through the X
thousand errors it highlights and fix them.

But using jsp, there was no way to find these errors without checking every
damm page!

The check, fix, build, deploy, recheck cycle takes about 3 mins per
itteration!
The same process for java files in eclipse takes a matter of seconds!

Kind of ironic eh?

 -Original Message-
 From: Jim Barrows [mailto:[EMAIL PROTECTED]
 Sent: 27 August 2004 18:35
 To: Struts Users Mailing List
 Subject: RE: philosophical question/poll about Struts/JSTL, scriptlets




  -Original Message-
  From: Woodchuck [mailto:[EMAIL PROTECTED]
  Sent: Friday, August 27, 2004 10:22 AM
  To: struts
  Subject: philosophical question/poll about Struts/JSTL, scriptlets
 
 
  sorry to bring this up on a Friday...
 
  does everyone here have pure Struts/JSTL jsp pages that is absolutely
  void of scriptlets?

 Every single one but the main layout page, because I haven't
 figured out a better way to use tiles putList.
 I avoid them like the plague they're almost, imho, as bad as
 javascript.  Then again I have nightmares about
 out.println(html)...

 
  or do you have jsp pages that use a combination of Struts/JSTL and
  scriptlets, all living together harmoniously using whichever method is
  easiest/cleanest?

 Depends.. I turn everything over to a html person.  The lesss
 scriptlets I use the happier she is.


 
  is mixing Struts/JSTL with traditional scriptlets a bad thing?

 I thinks so... ymmmv

 
  i have to say that i would prefer to *not* mix scriptlets with
  Struts/JSTL but in some situations it seems scriptlets is the better
  solution (in terms of code maintainability).  that is, it would be
  easier to use a little snippet of scriptlet here and there instead of
  making a round-about (albeit clever) and more verbose way of doing the
  same thing without scriptlets...

 Depends on what you're talking about.. and who you're talking
 about.  If your code is never going to be seen by anybody but
 java programmers,then you may be correct.

 
  any opinions is welcome!  i want to be able to sleep without
  nightmares
  about this!!  :)

 Most programmers would probably find that the scriptlets are
 somewhat easier...however I also look at tags as method calls, in
 terms of encapsulation.   I don't need to know what they do, just
 that they do it.  I don't really care how html:radio generates a
 radio html bit, just that it does so in a manner that makes my
 life easier, like only having to know the property name etc. etc.
 I have several tags that print lists of things change the tag
 and I've changed the way the lists are retrieved.  That can be
 harder to do in a scriptlet.
 Using scriptlets, to me is like going back to the bad old days of
 out.println(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]



  1   2   >