[Newbie] ActionForm with a scope session
Hi, I have defined in my struts-config.xml an ActionForm with a scope session. Here's the struts-config code: actionpath=/searchbydate type=be.stluc.info.struts.SearchByDateAction name=searchbydateform scope=session forward name=successProject path=/projectdetails.do / forward name=successParticipant path=/participantdetails.do / forward name=successAllProject path=/allprojectdetails.do / forward name=successAllParticipant path=/allparticipantdetails.do / forward name=baddates path=/baddates.html / forward name=error path=/error.html / /action The first time I use it in my java code, it works allright, but when I want to use it in a second Action class, it doesn't work anymore :( Here's my java code: HttpSession session = request.getSession(); SearchByDateForm sdf = (SearchByDateForm) session.getAttribute(searchbydateform); if (sdf == null) { return mapping.findForward(noForm); } I'm sure it's just a simple error, but I can't find it :( Any pointer would be greatly appreciated. Friendly Regards, Slimane -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Use of stuts in J2EE
Hi Dave, Thanks for that info. I have one question. When your formbean captures the data that the user has submitted, how do you pass this data to the app layer? If you pass the same form bean, then your app layer is not usable by other clients (or they will also have to implement struts). Basically my question is, how do you process your form bean into a data object? If you create another data object at this point, isnt that a performance overhead? Rgs Vikram -Original Message- From: Dave J Dandeneau [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 10:10 AM To: [EMAIL PROTECTED] Subject: RE: Use of stuts in J2EE We are currently implementing a j2ee / struts project. If I had any advice to you it would be to make sure you read up about common j2ee patterns. They can save you a lot of time and help you avoid some of the common EJB problems. We are using a command pattern which works very well. It is similiar to a session facade pattern where there are session beans that run all of the logic on the ejb container and send only the results back to the actions. This helps reduce network overhead, and makes transactions very simple. There are a million different patterns out there, and the most common ones are available at Sun's site: http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/ Other than that I don't think that working with struts and EJBs is much different than working with EJBs on a non-struts application. Thanks, dave dandeneau -Original Message- From: Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 10:50 PM To: [EMAIL PROTECTED] Subject: Use of stuts in J2EE Hi all, I am implementing a J2EE (Enterprise application with EJBs) project using struts. If anyone has done a similar project and would like to share some guidelines please mail back to me. Alternatively, if you have any online pointers, articles etc. please forward these as well. Regards Vikram Goyal -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: ActionForm reset
http://www.mail-archive.com/struts-user@jakarta.apache.org/msg13402.html --- Struts Newsgroup [EMAIL PROTECTED] wrote: Subject: ActionForm reset From: Donny Ryan Chong [EMAIL PROTECTED] === Hi, Anybody know when will the actionform call the reset method ? Thanks in advance Donny Ryan Chong -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) The server seems to have a problem during the generation of the class from the JSP page :-( I think that it is related to the use of the Struts taglibs. Is anyone know this problem ?? thanks. Arnaud HERITIER EAI Consulting Sopra Group Tel. : +33 (0)1 53 33 44 74 email : [EMAIL PROTECTED] Ce message est exclusivement destine aux personnes dont le nom figure ci-dessus. Il peut contenir des informations confidentielles dont la divulgation est a ce titre rigoureusement interdite. Dans l'hypothese ou vous avez recu ce message par erreur, merci de le renvoyer a l'adresse e-mail ci-dessus et de detruire toute copie. This message may contain confidential and proprietary material for the sole use of the intended recipient. Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
It's nothing to do with weblogic, I'm working with struts, taglib, templates, weblogic 6.1, be more specific about your doing. -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:28 AM To: 'Struts Users Mailing List' Subject: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) The server seems to have a problem during the generation of the class from the JSP page :-( I think that it is related to the use of the Struts taglibs. Is anyone know this problem ?? thanks. Arnaud HERITIER EAI Consulting Sopra Group Tel. : +33 (0)1 53 33 44 74 email : [EMAIL PROTECTED] Ce message est exclusivement destine aux personnes dont le nom figure ci-dessus. Il peut contenir des informations confidentielles dont la divulgation est a ce titre rigoureusement interdite. Dans l'hypothese ou vous avez recu ce message par erreur, merci de le renvoyer a l'adresse e-mail ci-dessus et de detruire toute copie. This message may contain confidential and proprietary material for the sole use of the intended recipient. Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [Newbie] ActionForm with a scope session
it doesn't work anymore what's the exact problem, exception or form there but values not set as expected or what? If you create a constructor for your form print your form variable (ie' 'this' in it ( in the reset method too) you'll be able to make sure you only have 1 version of the form that you are 'talking' to the one you think you are. --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, I have defined in my struts-config.xml an ActionForm with a scope session. Here's the struts-config code: actionpath=/searchbydate type=be.stluc.info.struts.SearchByDateAction name=searchbydateform scope=session forward name=successProject path=/projectdetails.do / forward name=successParticipant path=/participantdetails.do / forward name=successAllProject path=/allprojectdetails.do / forward name=successAllParticipant path=/allparticipantdetails.do / forward name=baddates path=/baddates.html / forward name=error path=/error.html / /action The first time I use it in my java code, it works allright, but when I want to use it in a second Action class, it doesn't work anymore :( Here's my java code: HttpSession session = request.getSession(); SearchByDateForm sdf = (SearchByDateForm) session.getAttribute(searchbydateform); if (sdf == null) { return mapping.findForward(noForm); } I'm sure it's just a simple error, but I can't find it :( Any pointer would be greatly appreciated. Friendly Regards, Slimane -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Tiles and struts action
Hello, Your definitions seem ok, except the url in value=jobList.do should better start with a /. You can encountered an error like this when one of the inserted Tiles has itself an error. Check each Tile separately (call their urls) to know which one fail. Actually, more appropriate list for Struts and Tiles related question is struts user list ;-), so I move this thread there. Cedric Hill, Donald wrote: I am trying to use a struts action in a tile definition, something like this. definition name=site.mainLayout path=/layouts/classicLayout.jsp put name=title value=Tiles Blank Site / put name=header value=/tiles/common/header.jsp / put name=menu value=site.menu.bar / put name=footer value=/tiles/common/footer.jsp / put name=body value=/tiles/body.jsp / /definition definition name=site.index.page extends=site.mainLayout put name=title value=Tiles Blank Site Index / put name=body value=jobList.do / /definition I always get a Response has been committed on the template page. Is there a trick to using a struts action in tiles or template tags that I am missing. -Don- -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
When I access to the first page of my web app I received the error mentioned below. My page is not very complex in comparison to others. I attach it if you want to see. Do you use WLS 6.1 with the SP2 ?? I hearded that there are several new bugs in the SP2 :-( It's nothing to do with weblogic, I'm working with struts, taglib, templates, weblogic 6.1, be more specific about your doing. -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:28 AM To: 'Struts Users Mailing List' Subject: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) The server seems to have a problem during the generation of the class from the JSP page :-( I think that it is related to the use of the Struts taglibs. Is anyone know this problem ?? thanks. Arnaud HERITIER EAI Consulting Sopra Group Tel. : +33 (0)1 53 33 44 74 email : [EMAIL PROTECTED] Ce message est exclusivement destine aux personnes dont le nom figure ci-dessus. Il peut contenir des informations confidentielles dont la divulgation est a ce titre rigoureusement interdite. Dans l'hypothese ou vous avez recu ce message par erreur, merci de le renvoyer a l'adresse e-mail ci-dessus et de detruire toute copie. This message may contain confidential and proprietary material for the sole use of the intended recipient. Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] identification.jsp Description: Binary data -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [Newbie] ActionForm with a scope session
Hi, sorry that I didn't mention it :) The error is that my form (which normally should have a scope session) is null ! so, when I run the app, it throws a java.lang.NullException, because I try to use sdf which is null (that's why I made a test to see if sdf == null, in that case my mapping returns an error page) To summarize, the problem isn't that I have wrong values, but that my form seems to not have a scope session (although it does have the mention session in the struts-config.xml) Thanx for your answer and sorry that I wasn't clear enough. Friendly Regards, Slimane At 01:42 13/03/2002 -0800, you wrote: it doesn't work anymore what's the exact problem, exception or form there but values not set as expected or what? If you create a constructor for your form print your form variable (ie' 'this' in it ( in the reset method too) you'll be able to make sure you only have 1 version of the form that you are 'talking' to the one you think you are. --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, I have defined in my struts-config.xml an ActionForm with a scope session. Here's the struts-config code: actionpath=/searchbydate type=be.stluc.info.struts.SearchByDateAction name=searchbydateform scope=session forward name=successProject path=/projectdetails.do / forward name=successParticipant path=/participantdetails.do / forward name=successAllProject path=/allprojectdetails.do / forward name=successAllParticipant path=/allparticipantdetails.do / forward name=baddates path=/baddates.html / forward name=error path=/error.html / /action The first time I use it in my java code, it works allright, but when I want to use it in a second Action class, it doesn't work anymore :( Here's my java code: HttpSession session = request.getSession(); SearchByDateForm sdf = (SearchByDateForm) session.getAttribute(searchbydateform); if (sdf == null) { return mapping.findForward(noForm); } I'm sure it's just a simple error, but I can't find it :( Any pointer would be greatly appreciated. Friendly Regards, Slimane -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: sturts example
Subject: Re: sturts example From: Pim [EMAIL PROTECTED] === In WSAD: Create a webapplication then import the war by File-import, choose war file. Even I figured this out, so it isn't very difficult :) Pim K J [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... I'm not using tomcat. i'm using websphere webserver with WSAD. But I will try it anyway. Thanks. --- nsg [EMAIL PROTECTED] wrote: Put that file named struts-example.war into YOUR-TOMCAT-HOME\webapps\ and then,restart tomcat.enter the url: http://localhost:8080/struts-example ,you will see the example. - Original Message - From: K J [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 8:47 AM Subject: sturts example Are there any docs on how to get the struts example to run? __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
After looking at the code of struts, I realized that there's not a ActionMessages class in the org.apache.struts.action package :-( I continue to follow this trail ... -Message d'origine- De: Arnaud Heritier [SMTP:[EMAIL PROTECTED]] Date: mercredi 13 mars 2002 10:48 A:'Struts Users Mailing List' Objet:RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs When I access to the first page of my web app I received the error mentioned below. My page is not very complex in comparison to others. I attach it if you want to see. Do you use WLS 6.1 with the SP2 ?? I hearded that there are several new bugs in the SP2 :-( It's nothing to do with weblogic, I'm working with struts, taglib, templates, weblogic 6.1, be more specific about your doing. -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:28 AM To: 'Struts Users Mailing List' Subject: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) The server seems to have a problem during the generation of the class from the JSP page :-( I think that it is related to the use of the Struts taglibs. Is anyone know this problem ?? thanks. Arnaud HERITIER EAI Consulting Sopra Group Tel. : +33 (0)1 53 33 44 74 email : [EMAIL PROTECTED] Ce message est exclusivement destine aux personnes dont le nom figure ci-dessus. Il peut contenir des informations confidentielles dont la divulgation est a ce titre rigoureusement interdite. Dans l'hypothese ou vous avez recu ce message par erreur, merci de le renvoyer a l'adresse e-mail ci-dessus et de detruire toute copie. This message may contain confidential and proprietary material for the sole use of the intended recipient. Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For
can anyone help me??
Hi, am new to struts. can anyone help me?? What does the below error message mean??? javax.servlet.ServletException: Cannot find bean user in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:459) at _0002findex_0002ejspindex_jsp_5._jspService(_0002findex_0002ejspindex_jsp_5. java:692) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherIm pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.ja va:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) Raghuramudu Vaddiyar SIS SEGAINTERSETTLE AG Front End Development P.O. Box CH-8002 Zurich Phone + 41-1-288-4488 Fax +41-1-288-4428 mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Use of stuts in J2EE
Personally I like to use two kind of data object, one that contains all screen datas ( ViewDataObject ) and an other one that comes from the persistence layer ( PerDataObject ). My Action class receive the ViewData object and if needed copy datas to the ActionForm. This permit to separate pure application development from the GUI development with Struts. In resume I have the followings class: 1) Persistence Layer contains PerData object: They are mapped to a table of my Database and have only getter and setter methods. Per object (Actually they are not EJB, sorry): They contains my JDBC transactions, with the followings methods save(), delete(), findByPrimaryKey() and findAll(). All methods receive PerDataObject. 2) Presentation layer: ViewData object: Are mapped to a screen of my application and have only getter and setter methods. Controller object: They aggregate if needed, PerData object and do some presentation manipulation. The Controller object is used by the Action class. For the business layer, if you need one, you can create Bus object and BusinessData object. Your presentation layer will receive BusData object. The other solution is to use your Business object directly into the Controller. If you are using EJB's for the persistence layer, i suggest you to add a Connector object between layers or use the Proxy Pattern. Certainly my pattern is not perfect, but we develop in this way sufficiently fast and the code is reusable. I will appreciate any comment, suggestion to improove, this design pattern. Regards -Message d'origine- De : Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Envoyé : mercredi, 13. mars 2002 09:52 À : Struts Users Mailing List Objet : RE: Use of stuts in J2EE Hi Dave, Thanks for that info. I have one question. When your formbean captures the data that the user has submitted, how do you pass this data to the app layer? If you pass the same form bean, then your app layer is not usable by other clients (or they will also have to implement struts). Basically my question is, how do you process your form bean into a data object? If you create another data object at this point, isnt that a performance overhead? Rgs Vikram -Original Message- From: Dave J Dandeneau [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 10:10 AM To: [EMAIL PROTECTED] Subject: RE: Use of stuts in J2EE We are currently implementing a j2ee / struts project. If I had any advice to you it would be to make sure you read up about common j2ee patterns. They can save you a lot of time and help you avoid some of the common EJB problems. We are using a command pattern which works very well. It is similiar to a session facade pattern where there are session beans that run all of the logic on the ejb container and send only the results back to the actions. This helps reduce network overhead, and makes transactions very simple. There are a million different patterns out there, and the most common ones are available at Sun's site: http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/ Other than that I don't think that working with struts and EJBs is much different than working with EJBs on a non-struts application. Thanks, dave dandeneau -Original Message- From: Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 10:50 PM To: [EMAIL PROTECTED] Subject: Use of stuts in J2EE Hi all, I am implementing a J2EE (Enterprise application with EJBs) project using struts. If anyone has done a similar project and would like to share some guidelines please mail back to me. Alternatively, if you have any online pointers, articles etc. please forward these as well. Regards Vikram Goyal -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: can anyone help me??
I'm not a magician you know, describe, what you are doing. -Original Message- From: Vaddiyar, Raghuramudu [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:58 AM To: Struts (E-mail) Subject: can anyone help me?? Hi, am new to struts. can anyone help me?? What does the below error message mean??? javax.servlet.ServletException: Cannot find bean user in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:459) at _0002findex_0002ejspindex_jsp_5._jspService(_0002findex_0002ejspindex_jsp_5. java:692) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherIm pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.ja va:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) Raghuramudu Vaddiyar SIS SEGAINTERSETTLE AG Front End Development P.O. Box CH-8002 Zurich Phone + 41-1-288-4488 Fax +41-1-288-4428 mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
servlet-mapping not available
Subject: servlet-mapping not available From: Sebastian Teister [EMAIL PROTECTED] === Hi! after developing a web-app locally I tried to get it run on our linux server. Unfortunately the servlet-mapping (*.do) seems to be unknown to the server, so it comments the mapping home.do as unknown (requested url not found). web.xml and struts-config seem to be valid. We already have a web-app running on our server that is an organizer we have bought. maybe i should handle this fact properly - as far as i know, tomcat's server.xml seems to be valid, too. Direct requests to jsps work. All classes and the struts are working. I'm using struts with tomcat 3.2.1 and apache. Any idea what the matter is? Please help. Sebastian -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Form Bean to Value Object Conversion ... URGENT!!!
Hi, We are facing a problem of converting Struts form beans to value objects and vice-versa. We use value objects as coarse grained data returned from the app tier. Value objects by virtue of their nature of representing persistent data, are immutable. Form beans on the other hand are more volatile and represent data that the user is changing. Hence they need to be separate implying a conversion of one unto the other during read and writes. When for instance, a set of value objects is read from the app tier before an update operation, the value objects need to be converted into Form beans to be edited by the user. One way to do the conversion is to localize the process at each form bean - however, we wanted to promote the conversion at a framework level. The generic conversion could be problematic in cases where deep hierarchies of value objects are encountered and more so in case where relations are one to many. Has any one in this list faced such a problem an are there any generic design patterns as a solution? Or am I making sense at all? Thanx in advance, VD. __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Need help with JspException: Missing message for key login.title
Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directory and here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet-classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, Ipswich IP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entity named above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this information is prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: can anyone help me??
Hello, I had the same exception when I started using Struts. This is caused probalbly because you have not created the bean . Make sure that you have created the user bean either from within your Action class (getServletContext.setAttribute(user, userclass) or from your .jsp file (jsp:useBean id=user scope=session type=class.User/). Of cource make sure that your Action class is being called before the jsp is dislayed(that you have done the right mappings) Try it and it should work. Konstantina - Original Message - From: Vaddiyar, Raghuramudu [EMAIL PROTECTED] To: Struts (E-mail) [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 11:57 AM Subject: can anyone help me?? Hi, am new to struts. can anyone help me?? What does the below error message mean??? javax.servlet.ServletException: Cannot find bean user in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:459) at _0002findex_0002ejspindex_jsp_5._jspService(_0002findex_0002ejspindex_jsp_5. java:692) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherIm pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.ja va:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) Raghuramudu Vaddiyar SIS SEGAINTERSETTLE AG Front End Development P.O. Box CH-8002 Zurich Phone + 41-1-288-4488 Fax +41-1-288-4428 mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Need help with JspException: Missing message for keylogin.title
YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entitynamed above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this informationis prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:struts-user- [EMAIL PROTECTED]For additional commands, e-mail: mailto:[EMAIL PROTECTED] **Disclaimer Information contained in this E-MAIL being proprietary to Wipro Limited is 'privileged' and 'confidential' and intended for use only by the individual or entity to which it is addressed. You are notified that any use, copying or dissemination of the information contained in the E-MAIL in any manner whatsoever is strictly prohibited. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: servlet-mapping not available
If you have apache and tomcat set up on the linux box, your problem could be related to how tomcat is configured to run with apache. Often tomcat and apache are set up so that servlets are required to live under the /servlet URL-mapping at your server, therefor try this in your web.xml-file: servlet-mappingservlet-nameaction/servlet-nameurl-pattern/servlet/do/*/url-pattern/servlet-mapping instead of servlet-mappingservlet-nameaction/servlet-nameurl-pattern/do/*/url-pattern/servlet-mapping or, if you really prefer *.do, try (in the url-pattern-tag) /servlet/*.do rather than *.do! // markus skyttner -Original Message- From: Struts Newsgroup (@Basebeans.com) [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 11:25 To: [EMAIL PROTECTED] Subject: servlet-mapping not available Subject: servlet-mapping not available From: Sebastian Teister [EMAIL PROTECTED] === Hi! after developing a web-app locally I tried to get it run on our linux server. Unfortunately the servlet-mapping (*.do) seems to be unknown to the server, so it comments the mapping home.do as unknown (requested url not found). web.xml and struts-config seem to be valid. We already have a web-app running on our server that is an organizer we have bought. maybe i should handle this fact properly - as far as i know, tomcat's server.xml seems to be valid, too. Direct requests to jsps work. All classes and the struts are working. I'm using struts with tomcat 3.2.1 and apache. Any idea what the matter is? Please help. Sebastian -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: html:base and tiles - uses layout path
Cedric I have the same problem. Don't you have to use a version with the server and port? base href=%= http://; + request.getServerName()+:+ request.getServerPort()+request.getContextPath()% / Cal -Original Message- From: Cedric Dumoulin [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 07, 2002 04:47 To: Struts Users Mailing List Subject: Re: html:base and tiles - uses layout path Hello, I don't know why html:base ... act like this (need some investigation), but you could replace it by : base href=%=request.getContextPath()% / Hope this help, Cedric Matt Raible wrote: I am using the html:base/ tag in my baseLayout.jsp file. I was hoping this would simply render the host + context of my application, however it gives the full path to my base tiles template. Any ideas? My idea is to just do away with it. Here's what it renders: base href=http://localhost/onpoint/layouts/baseLayout.jsp; Thanks, Matt __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Use of stuts in J2EE
We have created value objects that we store within our form. The value objects a implement different interfaces and the forms have these objects has member variables. For instance a registration form may have a few fields that aren't persisted and then a registrationInput object which implements the address interface and the security interface. We pass the inputs directly to the commands and then to the EJBs. The input value objects are not tied to web / struts implementation and can be reused. Because both the EJBs and the input objects implement the same interfaces we can use helper methods to copy properties from one to another. Thanks, dave -Original Message- From: Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 3:52 AM To: Struts Users Mailing List Subject: RE: Use of stuts in J2EE Hi Dave, Thanks for that info. I have one question. When your formbean captures the data that the user has submitted, how do you pass this data to the app layer? If you pass the same form bean, then your app layer is not usable by other clients (or they will also have to implement struts). Basically my question is, how do you process your form bean into a data object? If you create another data object at this point, isnt that a performance overhead? Rgs Vikram -Original Message- From: Dave J Dandeneau [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 10:10 AM To: [EMAIL PROTECTED] Subject: RE: Use of stuts in J2EE We are currently implementing a j2ee / struts project. If I had any advice to you it would be to make sure you read up about common j2ee patterns. They can save you a lot of time and help you avoid some of the common EJB problems. We are using a command pattern which works very well. It is similiar to a session facade pattern where there are session beans that run all of the logic on the ejb container and send only the results back to the actions. This helps reduce network overhead, and makes transactions very simple. There are a million different patterns out there, and the most common ones are available at Sun's site: http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/ Other than that I don't think that working with struts and EJBs is much different than working with EJBs on a non-struts application. Thanks, dave dandeneau -Original Message- From: Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 10:50 PM To: [EMAIL PROTECTED] Subject: Use of stuts in J2EE Hi all, I am implementing a J2EE (Enterprise application with EJBs) project using struts. If anyone has done a similar project and would like to share some guidelines please mail back to me. Alternatively, if you have any online pointers, articles etc. please forward these as well. Regards Vikram Goyal -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: can anyone help me??
Yes. Read the following: http://www.tuxedo.org/~esr/faqs/smart-questions.html -Original Message- From: Vaddiyar, Raghuramudu [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 4:58 AM Hi, am new to struts. can anyone help me?? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Help needed in define tag..........urgent
To begin with, what's the point of storing the package name in a variable? The problem is that test2 is assigned at run time, while type is assigned at compile time (or is it the other way around? - I forget). The container is trying to assign a package name to type that doesn't yet exist. Mark -Original Message- From: Piyush Srivastava [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 12:26 AM To: Struts Users Mailing List Subject: Help needed in define tag..urgent hi, I am facing problem with the bean:define tag provided by struts. When I directly give the package name for the type attribute, it works fine but when we define a variable to refer the package name and use it through JSP expression for the type attribute. It throws class cast exception. To elaborate... The code given below works fine : bean:define id=formTest scope=session name=test type=com.egm.fusion.VehicleForm / but if I give %String test2 = com.egm.fusion.VehicleForm;% bean:define id=formTest scope=session name=test type=%=test2% / It gives the following exception java.lang.ClassCastException: java.lang.Object at org.apache.struts.taglib.bean.DefineTei.getVariableInfo(DefineTei.java:87) Can anybody help on this. Regards, Piyush __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Use of stuts in J2EE
We are doing the same thing with a large, complex project for VoiceStream and I could not agree more! Mark -Original Message- From: Dave J Dandeneau [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 11:40 PM To: [EMAIL PROTECTED] Subject: RE: Use of stuts in J2EE We are currently implementing a j2ee / struts project. If I had any advice to you it would be to make sure you read up about common j2ee patterns. They can save you a lot of time and help you avoid some of the common EJB problems. We are using a command pattern which works very well. It is similiar to a session facade pattern where there are session beans that run all of the logic on the ejb container and send only the results back to the actions. This helps reduce network overhead, and makes transactions very simple. There are a million different patterns out there, and the most common ones are available at Sun's site: http://developer.java.sun.com/developer/technicalArticles/J2EE/patterns/ Other than that I don't think that working with struts and EJBs is much different than working with EJBs on a non-struts application. Thanks, dave dandeneau -Original Message- From: Vikram Goyal01 [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 10:50 PM To: [EMAIL PROTECTED] Subject: Use of stuts in J2EE Hi all, I am implementing a J2EE (Enterprise application with EJBs) project using struts. If anyone has done a similar project and would like to share some guidelines please mail back to me. Alternatively, if you have any online pointers, articles etc. please forward these as well. Regards Vikram Goyal -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: sturts example
Yes. -Original Message- From: K J [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 6:48 PM To: [EMAIL PROTECTED] Subject: sturts example Are there any docs on how to get the struts example to run? __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: What do you call them beans?
Clever. :-) -Original Message- From: Adam Hardy [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 4:18 PM I was thinking . . . of calling them HasBeans. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Need help with JspException: Missing message for keylogin.title
Lindsay - You don't say what IDE you are using. I'm also new to struts and I'm using WebSphere Application Developer 4.0. WSAD has *two* copies of the ApplicationResources.properties file. One under the applicationRoot/source folder and one under the applicationRoot/webApplication/WEB-INF/classes folder. For most of a day I made changes to the .../classes version only to discover it was overlaid by the .../source copy when I deployed the application. D'oh! I guess I'm saying make sure you are working with the right copy of the .properties file. /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/13/02 04:54AM Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directory and here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet-classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, Ipswich IP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entity named above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this information is prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: newbie
Tony, I too am new to struts and also to WebSphere Application Developer 4.0. (So new in fact I am still using the Trial Edition while the purchase order goes through... =) I started by creating projects for all the struts bits: documentation, example, taglib, upload, etc. I downloaded and read several times the strut-by-strut example from Ted Husted's site. (www.husted.com). Finally, in frustration at trying to understand what other people had done I just started building a simple application. I learned more from my trial and error attempts than I ever got from looking at the examples. With the context of my application in mind I was able to find and reuse code, tags, whatever, from the examples. I purchased a couple of books that helped my understanding as well. JSP and Tag Libraries for Web Development by Wellington L. S. da Silva (New Riders, isbn: 0-7357-1095-3) This has several chapters on Struts. Also, Professional JSP Site Design (Wrox, isbn: 1-861005-51-2) Again, several mentions of Struts, and one of the authors is Ted Husted. Use all the resources listed on the Struts Resources page (http://jakarta.apache.org/struts/resources.html). HTH, /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/12/02 04:04PM I just downloaded struts and trying to create a simple web application and see it in action. Im using websphere4.0/WSAD. Whats the best way to get started? Should I try to get the struts example working with websphere instead of creating my own example? If so, do I only need to extract the files in struts-example.war and start the web server? I need to be pointed to the right direction understand struts .thanks! __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Passing objects in Custom tags
Not with HTTP. Mark -Original Message- From: Syed Niaz [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 11:07 AM To: Struts Users Mailing List Subject: Passing objects in Custom tags Hi Is it possible to pass objects as attributes in Custom tags ? (and without using a scripting variable) eg : tagaa:aa attr1=some string attr2=some object / Thanks -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: newbie
I learned more from my trial and error attempts than I ever got from looking at the examples. Exactly! It's like learning driving - plenty of theory study is needed but you you have to clock up the hours actually doing it. --- MARK NICHOLS [EMAIL PROTECTED] wrote: Tony, I too am new to struts and also to WebSphere Application Developer 4.0. (So new in fact I am still using the Trial Edition while the purchase order goes through... =) I started by creating projects for all the struts bits: documentation, example, taglib, upload, etc. I downloaded and read several times the strut-by-strut example from Ted Husted's site. (www.husted.com). Finally, in frustration at trying to understand what other people had done I just started building a simple application. I learned more from my trial and error attempts than I ever got from looking at the examples. With the context of my application in mind I was able to find and reuse code, tags, whatever, from the examples. I purchased a couple of books that helped my understanding as well. JSP and Tag Libraries for Web Development by Wellington L. S. da Silva (New Riders, isbn: 0-7357-1095-3) This has several chapters on Struts. Also, Professional JSP Site Design (Wrox, isbn: 1-861005-51-2) Again, several mentions of Struts, and one of the authors is Ted Husted. Use all the resources listed on the Struts Resources page (http://jakarta.apache.org/struts/resources.html). HTH, /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/12/02 04:04PM I just downloaded struts and trying to create a simple web application and see it in action. Im using websphere4.0/WSAD. Whats the best way to get started? Should I try to get the struts example working with websphere instead of creating my own example? If so, do I only need to extract the files in struts-example.war and start the web server? I need to be pointed to the right direction understand struts .thanks! __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Why no struts.jar on the classpath?
True, but I NEED a good laugh on Fridays! :-) Simon -Original Message- From: MARK NICHOLS [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 12:36 PM To: [EMAIL PROTECTED] Subject: RE: Why no struts.jar on the classpath? Who cares! A good chuckle on Tuesday is better than a delayed laugh on Friday. /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/12/02 11:24AM It's not Friday yet! :-) -Original Message- From: Galbreath, Mark [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 11:17 AM To: 'Struts Users Mailing List' Subject: RE: Why no struts.jar on the classpath? Struts is actually a virus, though the delivery is a bit low-tech. Mark -Original Message- From: Chappell, Simon P [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 12:15 PM To: Struts mailing list (E-mail) Subject: Why no struts.jar on the classpath? I want to start out by saying that I have read the fine manual and realise that the struts FAQ says that the struts.jar must not be placed on the application server's CLASSPATH. My question to this list is why is this the case? I have a build manager who very much wants only a single instance of any jar file to exist on a server and they are asking why I am talking about putting multiples of the same file on their machine? Simon - Simon P. Chappell [EMAIL PROTECTED] Java Programming Specialist www.landsend.com Lands' End, Inc. (608) 935-4526 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:struts-user-[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:struts-user-[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: sturts example
they are here (or here-abouts). http://jakarta.apache.org/struts/kickstart.html + lots of stuff in the mail archive http://www.mail-archive.com/struts-user%40jakarta.apache.org/ (We can do a double act Mark!). I notice it says sturts in the title, my reply is about struts which is probably pretty similar! --- Galbreath, Mark [EMAIL PROTECTED] wrote: Yes. -Original Message- From: K J [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 6:48 PM To: [EMAIL PROTECTED] Subject: sturts example Are there any docs on how to get the struts example to run? __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: sturts example
:-)~ -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 8:46 AM To: Struts Users Mailing List Subject: RE: sturts example they are here (or here-abouts). http://jakarta.apache.org/struts/kickstart.html + lots of stuff in the mail archive http://www.mail-archive.com/struts-user%40jakarta.apache.org/ (We can do a double act Mark!). I notice it says sturts in the title, my reply is about struts which is probably pretty similar! --- Galbreath, Mark [EMAIL PROTECTED] wrote: Yes. -Original Message- From: K J [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 6:48 PM To: [EMAIL PROTECTED] Subject: sturts example Are there any docs on how to get the struts example to run? __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Need help with JspException: Missing message for key login.title
not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entitynamed above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this informationis prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:struts-user- [EMAIL PROTECTED]For additional commands, e-mail: mailto:[EMAIL PROTECTED] **Disclaimer Information contained in this E-MAIL being proprietary to Wipro Limited is 'privileged' and 'confidential' and intended for use only by the individual or entity to which it is addressed. You are notified that any use, copying or dissemination of the information contained in the E-MAIL in any manner whatsoever is strictly prohibited. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: can anyone help me??
Cannot find bean user in scope null This is a bit mis-leading. I think it means you have used bean:define or bean:write - a tag where struts searches for the bean. You haven't specified scope... so struts searches all possible scope (page,request,session,application) hope that helps. --- Konstantina Stamopoulou [EMAIL PROTECTED] wrote: Hello, I had the same exception when I started using Struts. This is caused probalbly because you have not created the bean . Make sure that you have created the user bean either from within your Action class (getServletContext.setAttribute(user, userclass) or from your .jsp file (jsp:useBean id=user scope=session type=class.User/). Of cource make sure that your Action class is being called before the jsp is dislayed(that you have done the right mappings) Try it and it should work. Konstantina - Original Message - From: Vaddiyar, Raghuramudu [EMAIL PROTECTED] To: Struts (E-mail) [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 11:57 AM Subject: can anyone help me?? Hi, am new to struts. can anyone help me?? What does the below error message mean??? javax.servlet.ServletException: Cannot find bean user in scope null at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImp l.java:459) at _0002findex_0002ejspindex_jsp_5._jspService(_0002findex_0002ejspindex_jsp_5. java:692) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspCountedServlet.service(JspServlet.ja va:130) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja va:282) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:429) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:500) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherIm pl.java:222) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl .java:162) at org.apache.struts.action.ActionServlet.processActionForward(ActionServlet.ja va:1759) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1596) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:81 2) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC onnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501) at java.lang.Thread.run(Thread.java:484) Raghuramudu Vaddiyar SIS SEGAINTERSETTLE AG Front End Development P.O. Box CH-8002 Zurich Phone + 41-1-288-4488 Fax +41-1-288-4428 mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
I think ActionMessages is in the new version (from the nightly build) but not in the stable version. (If that's the name of the thing like ActionErrors but not for errors). ie. you are running new code on old version of struts. --- Arnaud Heritier [EMAIL PROTECTED] wrote: After looking at the code of struts, I realized that there's not a ActionMessages class in the org.apache.struts.action package :-( I continue to follow this trail ... -Message d'origine- De: Arnaud Heritier [SMTP:[EMAIL PROTECTED]] Date: mercredi 13 mars 2002 10:48 A: 'Struts Users Mailing List' Objet: RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs When I access to the first page of my web app I received the error mentioned below. My page is not very complex in comparison to others. I attach it if you want to see. Do you use WLS 6.1 with the SP2 ?? I hearded that there are several new bugs in the SP2 :-( It's nothing to do with weblogic, I'm working with struts, taglib, templates, weblogic 6.1, be more specific about your doing. -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:28 AM To: 'Struts Users Mailing List' Subject: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204) at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139) at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120) The server seems to have a problem during the generation of the class from the JSP page :-( I think that it is related to the use of the Struts taglibs. Is anyone know this problem ?? thanks. Arnaud HERITIER EAI Consulting Sopra Group Tel. : +33 (0)1 53 33 44 74 email : [EMAIL PROTECTED] Ce message est exclusivement destine aux personnes dont le nom figure ci-dessus. Il peut contenir des informations confidentielles dont la divulgation est a ce titre rigoureusement interdite. Dans l'hypothese ou vous avez recu ce message par erreur, merci de le renvoyer a
Re: [Newbie] ActionForm with a scope session
This code lets you see what is in your session request - usually nearly what you expect but spelled wrong! replace dbmd with what-ever you write log messages with (System.out.println probably). You can solve a lot of bugs with them. Ask again if that doesn't crack it! = //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printSessionAttributeNames(String caller, HttpSession session) { Enumeration ee3 = session.getAttributeNames(); dbmd(printSessionAttributeNames: for caller: + caller + - start...); while (ee3.hasMoreElements()) { String name = (String)ee3.nextElement(); Object object = session.getAttribute(name); String className = object == null ? null : object.getClass().getName(); dbmd(name + of class:+ className); } dbmd(printSessionAttributeNames: for caller: + caller + - end); } //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printRequestAttributeNames(String caller, HttpServletRequest request) { Enumeration ee2 = request.getAttributeNames(); dbmd(printRequestAttributeNames: for caller: + caller + - start...); while (ee2.hasMoreElements()) { String name = (String)ee2.nextElement(); Object object = request.getAttribute(name); String className = object == null ? null : object.getClass().getName(); dbmd(name + of class:+ className); } dbmd(printRequestAttributeNames: for caller: + caller + - end); } //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printRequestParameters(String caller, HttpServletRequest request) { Enumeration ee5 = request.getParameterNames(); dbmd(printRequestParameters: for caller: + caller + - start...); while (ee5.hasMoreElements()) { String name = (String)ee5.nextElement(); String[] values = request.getParameterValues(name); String print = name: + name + value(s): ; for (int ii5 = 0; ii5 values.length; ii5++) { print += values[ii5]; if (ii5 values.length - 1) { print += , ; } } dbmd(print); } dbmd(printRequestParameters: for caller: + caller + - end); } == --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, sorry that I didn't mention it :) The error is that my form (which normally should have a scope session) is null ! so, when I run the app, it throws a java.lang.NullException, because I try to use sdf which is null (that's why I made a test to see if sdf == null, in that case my mapping returns an error page) To summarize, the problem isn't that I have wrong values, but that my form seems to not have a scope session (although it does have the mention session in the struts-config.xml) Thanx for your answer and sorry that I wasn't clear enough. Friendly Regards, Slimane At 01:42 13/03/2002 -0800, you wrote: it doesn't work anymore what's the exact problem, exception or form there but values not set as expected or what? If you create a constructor for your form print your form variable (ie' 'this' in it ( in the reset method too) you'll be able to make sure you only have 1 version of the form that you are 'talking' to the one you think you are. --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, I have defined in my struts-config.xml an ActionForm with a scope session. Here's the struts-config code: actionpath=/searchbydate type=be.stluc.info.struts.SearchByDateAction name=searchbydateform scope=session forward name=successProject path=/projectdetails.do / forward name=successParticipant path=/participantdetails.do / forward name=successAllProject path=/allprojectdetails.do / forward name=successAllParticipant path=/allparticipantdetails.do / forward name=baddates path=/baddates.html / forward name=error path=/error.html / /action The first time I use it in my java code, it works allright, but when I want to use it in a second Action class, it
RE: Need help with JspException: Missing message for key login.ti tle
Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject:Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entitynamed above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this informationis prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:struts-user- [EMAIL PROTECTED]For additional commands, e-mail: mailto:[EMAIL PROTECTED] **Disclaimer Information contained in this E-MAIL being proprietary to Wipro Limited is 'privileged' and 'confidential' and intended for use only by the individual or entity to which it is addressed. You are notified that any use, copying or dissemination of the information contained in the E-MAIL in any manner whatsoever is strictly prohibited. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/
Nested Iterates...
Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: No getter - method order bug?
Hi Jon, Good debugging! I'd like to see some clear rules about struts bean properties, so here's my attempt. (Not having read the bean spec very carefully!). 1 - If you want something treated as a property you must have get set methods even if you won't call them both (from bean spec). 2 - Declare the get set methods together (not necessary but good standard) most people do get before the set. 3 - If you overload the methods keep the matched pairs together. This is alarmimg. I figure if if follow these rules I won't hit any problems. It seems you've discovered that it's dangerous to overload methods that are properties. Has some-one got the time to get to the bottom of this? cheers - Keith. --- Jon Ferguson [EMAIL PROTECTED] wrote: Hey guys, I've finally managed to get this to work.. I thought it would be a classpath prob.. but looks a bit more insidious. In my CategoryWrapper class I actually had three relevant methods: public void setMapping(int index) public void setMapping(Map) public Map getMapping() The first is only used for setting things up explicitly... However because it came before the others struts expects there to be a public int getMapping() method. Even though the one requred for the jsp is available. If I move Map getMapping() above the other two in my source code this works. Java does not guarrantee order when listing methods with getDeclaredMethods() so I suspect the logic:iterate tag is not testing the methods correctly? Any other takes on this? I realise I should probably change the name of the first method to something like initializeMapping(int index) but it doesn't seem like it should fail.. Especially since this is likely to be random. Cheers, Jon Jon Ferguson wrote: Hey guys, anybody see this?? I've had the particular exception before but it's always been apparent what it was [eg. me :-) ]. I'm developing on Linux and Windows 2k. I've built a struts/tiles app that works flawlessly under my linux setup but when I serve it from my Windows 2k box I'm getting : No getter method for property mapping of bean category when my jsp is hit. The offending code uses a logic:iterate as follows: logic:iterate id=category type=uk.co.omegasoftware.util.struts.CategoryWrapper name=itemListForm property=categoryWrappers tr td html:link page=/inventory.do name=category property=mapping bean:write name=category property=name filter=true/ /html:link /td /tr /logic:iterate the CategoryWrapper class Does have the appropriate accessors: ... public void setMapping(Map map) { mapping = map; } public Map getMapping() { return mapping; } ... In both cases I'm using release versions of struts. I've tried 1.0: 1.0.1 and 1.0.2 I'm running on Tomcat 4.0-b6 on my Linux box.. I've tried: Tomcat 4.0.1, 3.2.3, and 4.0 on my Windows box. I'm using JDK 1.4.0-beta on linux I've tried JDK 1.3.1, 1.4.0-beta and 1.4.0-beta3 on windows Any ideas?? Thanks, Jon Part 1.2Type: Plain Text (text/plain) -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Examples using struts tags
Hi Guys, Where can I find examples of jsp's using the tags from struts tag library ? I have gone thru all the examples which come with struts and also the tag library documentation. I am looking for examples. Thanks Sanjeev -Original Message- From: Marcelo Caldas [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 7:56 PM To: Struts Mailing List Subject: Nested Iterates... Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Form Bean to Value Object Conversion ... URGENT!!!
Hi VD/cool dude :-), there is a mapping framework referenced on Struts resouces page http://jakarta.apache.org/struts/resources.html In fact it points to a resouce on Ted Husted site : http://husted.com/struts/resources/mapper.htm I read through the documentation and it seems quite powerful. However I didn't had time yet to use it really, so I am not sure whether or not it will fit your needs nicely . If you happen to try/use it, could you please give me some feed back. Hope this help thanks Denis -Original Message- From: cool dude [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:44 AM To: [EMAIL PROTECTED] Subject: Form Bean to Value Object Conversion ... URGENT!!! Hi, We are facing a problem of converting Struts form beans to value objects and vice-versa. We use value objects as coarse grained data returned from the app tier. Value objects by virtue of their nature of representing persistent data, are immutable. Form beans on the other hand are more volatile and represent data that the user is changing. Hence they need to be separate implying a conversion of one unto the other during read and writes. When for instance, a set of value objects is read from the app tier before an update operation, the value objects need to be converted into Form beans to be edited by the user. One way to do the conversion is to localize the process at each form bean - however, we wanted to promote the conversion at a framework level. The generic conversion could be problematic in cases where deep hierarchies of value objects are encountered and more so in case where relations are one to many. Has any one in this list faced such a problem an are there any generic design patterns as a solution? Or am I making sense at all? Thanx in advance, VD. __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs
I found that the problem lied on the use of struts-layout taglibs (http://struts.application-servers.com) It seems that this taglib is not compiled with struts 1.0.2 but perhaps with a newer release. I don't know why but WLS search for the class ActionMessages even though this tag lib doesn't use it. I recompiles this taglib with struts 1.0.2 and now my application runs correctly. Thanks for your help. Arnaud -Message d'origine- De: keithBacon [SMTP:[EMAIL PROTECTED]] Date: mercredi 13 mars 2002 15:11 A:Struts Users Mailing List; [EMAIL PROTECTED] Objet:RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs I think ActionMessages is in the new version (from the nightly build) but not in the stable version. (If that's the name of the thing like ActionErrors but not for errors). ie. you are running new code on old version of struts. --- Arnaud Heritier [EMAIL PROTECTED] wrote: After looking at the code of struts, I realized that there's not a ActionMessages class in the org.apache.struts.action package :-( I continue to follow this trail ... -Message d'origine- De: Arnaud Heritier [SMTP:[EMAIL PROTECTED]] Date: mercredi 13 mars 2002 10:48 A:'Struts Users Mailing List' Objet:RE: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs When I access to the first page of my web app I received the error mentioned below. My page is not very complex in comparison to others. I attach it if you want to see. Do you use WLS 6.1 with the SP2 ?? I hearded that there are several new bugs in the SP2 :-( It's nothing to do with weblogic, I'm working with struts, taglib, templates, weblogic 6.1, be more specific about your doing. -Original Message- From: Arnaud Heritier [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:28 AM To: 'Struts Users Mailing List' Subject: Weblogic 6.1 SP2 and Struts 1.0.2 taglibs Hi all. I'm trying to deploy a web app on WLS 6.1 SP2. This Web app works very well under Tomcat 4 but under WLS I received this error : 13 mars 02 10:22:13 CET Error HTTP [WebAppServletContext(3167241,PFE,/PFE)] Servlet failed with Exception java.lang.NoClassDefFoundError: org/apache/struts/action/ActionMessages at java.lang.Class.getMethods0(Native Method) at java.lang.Class.getDeclaredMethods(Class.java:1039) at java.beans.Introspector$1.run(Introspector.java:852) at java.security.AccessController.doPrivileged(Native Method) at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:850) at java.beans.Introspector.getTargetEventInfo(Introspector.java:556) at java.beans.Introspector.getBeanInfo(Introspector.java:294) at java.beans.Introspector.getBeanInfo(Introspector.java:128) at weblogic.servlet.jsp.StandardTagLib.parseTagDD(StandardTagLib.java:1003) at weblogic.servlet.jsp.StandardTagLib.parseDD(StandardTagLib.ja va:941) at weblogic.servlet.jsp.StandardTagLib.init(StandardTagLib.java:207) at weblogic.servlet.jsp.JspLexer.loadTagLib(JspLexer.java:145) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE_BODY(JspLexer.java:4187) at weblogic.servlet.jsp.JspLexer.mTAGLIB_DIRECTIVE(JspLexer.java:4028) at weblogic.servlet.jsp.JspLexer.mDIRECTIVE(JspLexer.java:3875) at weblogic.servlet.jsp.JspLexer.mSTANDARD_THING(JspLexer.java:2048) at weblogic.servlet.jsp.JspLexer.mTOKEN(JspLexer.java:1862) at weblogic.servlet.jsp.JspLexer.nextToken(JspLexer.java:1744) at weblogic.servlet.jsp.JspLexer.parse(JspLexer.java:1023) at weblogic.servlet.jsp.JspParser.doit(JspParser.java:80) at weblogic.servlet.jsp.JspParser.parse(JspParser.java:183) at weblogic.servlet.jsp.Jsp2Java.outputs(Jsp2Java.java:119) at weblogic.utils.compiler.CodeGenerator.generate(CodeGenerator. java:255) at weblogic.servlet.jsp.JspStub.compilePage(JspStub.java:327) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:189) at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:154) at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.jav a:368) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:242) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:304) at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl. java:200) at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl etContext.java:2495) at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl. java:2204)
amount of data stored in session
Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations.
Best way to find referrer
I'm looking to find the best way to find the referring page (ie find out where the user came from). So far this is the piece of code I have... Enumeration e = request.getHeaderNames(); String refText = null; while (e.hasMoreElements()) { String key = (String)e.nextElement(); if (key.equals(referer)) { refText = request.getHeader(key); break; } } I have to imagine that there's a better way to do this..does anyone have any insight? I checked google and the servlet javadocs and didn't see anything that simplified this code. Otherwise, I'll just drop this piece of code into a util class. Just seeing if I'm reinventing the wheel. Thanks.
Re: Help with Oracle dates from Secs passed since 1970
Without looking it all up (maybe a bit wrong here). convert seconds into days (divide by 60 * 60 * 24) then use java.util.Date or GregorianCalendar to add that number of days to 1/1/1970. Then grapple with DateFormat objects!! I have some totally non-standard date code that I converted from VB after it was proved to me there was a nasty bug in java.util.Date. I can't remember exactly what the bug was but it made us ditch java dates straight away. I never saw it mentioned elsewhere but I guess you could assume there is no such bug now (or never was we were mis-guided). You can have my code if you ask, wouldn't want to put it on this list - it's un-orthodox might be held against me! I do believe you should write utility classes for validating/formatting dates so that enforce standards across your system. Then you can recode your date handling ad-nauseum. cheers - keith. --- SUPRIYA MISRA [EMAIL PROTECTED] wrote: If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Best way to find referrer
String refText = request.getHeader(referer); if (refText == null) { // no referer } -Original Message- From: John M. Corro [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 9:11 AM To: [EMAIL PROTECTED] Subject: Best way to find referrer I'm looking to find the best way to find the referring page (ie find out where the user came from). So far this is the piece of code I have... Enumeration e = request.getHeaderNames(); String refText = null; while (e.hasMoreElements()) { String key = (String)e.nextElement(); if (key.equals(referer)) { refText = request.getHeader(key); break; } } I have to imagine that there's a better way to do this..does anyone have any insight? I checked google and the servlet javadocs and didn't see anything that simplified this code. Otherwise, I'll just drop this piece of code into a util class. Just seeing if I'm reinventing the wheel. Thanks. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Help with Oracle dates from Secs passed since 1970
Isn't unix time equivalent to the java date divided by 1000? I thought the java date is in milliseconds since Jan 1, 1970. lol... well, at least that works for us. We have unix times tucked away in database fields that we multiply by 1000 to get java dates, like so: info.submitdate = new Date( rs.getLong( col++ ) * 1000 ); YMMV. Owen On Wed, 2002-03-13 at 09:57, SUPRIYA MISRA wrote: If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- USMail: Employment Specialists, LLC, 130 S. First, Ann Arbor, MI 48104 Phone:+1 734 213-9500 FAX:+1 240 266-2535 mailto:[EMAIL PROTECTED] http://www.careersite.com/~osm/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Help with Oracle dates from Secs passed since 1970
You can just convert seconds into milliseconds (*1000) and then use java.util.Date(milliseconds) to get your date which is Sep 21, 12:57:34 EDT 2001. Robert Nocera New England Open Solutions www.neosllc.com You supply the vision, we'll do the rest. -Original Message- From: SUPRIYA MISRA [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 9:58 AM To: [EMAIL PROTECTED] Subject: Help with Oracle dates from Secs passed since 1970 If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
JavaScript problem. please help me.
Dear friends, I have a strange problem. please help me I have to execute 2 scripting files in a html page (One is compatible for Internet explorer and anotherone is for netscape) ie.js netscape.js how can i call these 2 scripts in my html file to make compatible for both IE and Netscape. I have to use only one html file to run these scripts in their respective browsers My code in html page is like this.. (menu.html) !--First script for IE-- script language=JavaScript src=ie.js /script script language=JavaScript new menu (MENU_ITEMS, MENU_POS1, MENU_STYLES1); /script !--Second script for NetScript-- script language=JavaScript src=netscape.js /script Body leftmargin=0 rightmargin=0 topmargin=0 marginwidth=0 marginheight=0 onLoad=writeMenus() == end == if i execute these scripts individually, these are working. please help me how can i execute netscape.js in netscape browser and ie.js in internet explorer, with this single html file. Your kind cooperation would be greatly appreciated. Thanks in advance. Yours Sagar winmail.dat Description: application/ms-tnef -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Help with Oracle dates from Secs passed since 1970
ho ho - do it my way if you get paid by number of lines of code produced! --- keithBacon [EMAIL PROTECTED] wrote: Without looking it all up (maybe a bit wrong here). convert seconds into days (divide by 60 * 60 * 24) then use java.util.Date or GregorianCalendar to add that number of days to 1/1/1970. Then grapple with DateFormat objects!! I have some totally non-standard date code that I converted from VB after it was proved to me there was a nasty bug in java.util.Date. I can't remember exactly what the bug was but it made us ditch java dates straight away. I never saw it mentioned elsewhere but I guess you could assume there is no such bug now (or never was we were mis-guided). You can have my code if you ask, wouldn't want to put it on this list - it's un-orthodox might be held against me! I do believe you should write utility classes for validating/formatting dates so that enforce standards across your system. Then you can recode your date handling ad-nauseum. cheers - keith. --- SUPRIYA MISRA [EMAIL PROTECTED] wrote: If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Nested Iterates...
have u tried name=items.tests ?? Marcelo Caldas wrote: Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Nested Iterates...
Look at http://www.keyboardmonkey.com/struts/index.html - Original Message - From: Marcelo Caldas [EMAIL PROTECTED] Newsgroups: Struts To: Struts Mailing List [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 4:25 PM Subject: Nested Iterates... Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [Newbie] ActionForm with a scope session
THANX A LOT, you're my hero :) indeed it was a spelling mistake (damn, I can be stupid sometimes :( Again, THANX for the code, it was usefull this time and I'm sure I will resolve a lot of bugs in my future development :) Friendly Regards, Slimane At 06:17 13/03/2002 -0800, you wrote: This code lets you see what is in your session request - usually nearly what you expect but spelled wrong! replace dbmd with what-ever you write log messages with (System.out.println probably). You can solve a lot of bugs with them. Ask again if that doesn't crack it! = //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printSessionAttributeNames(String caller, HttpSession session) { Enumeration ee3 = session.getAttributeNames(); dbmd(printSessionAttributeNames: for caller: + caller + - start...); while (ee3.hasMoreElements()) { String name = (String)ee3.nextElement(); Object object = session.getAttribute(name); String className = object == null ? null : object.getClass().getName(); dbmd(name + of class:+ className); } dbmd(printSessionAttributeNames: for caller: + caller + - end); } //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printRequestAttributeNames(String caller, HttpServletRequest request) { Enumeration ee2 = request.getAttributeNames(); dbmd(printRequestAttributeNames: for caller: + caller + - start...); while (ee2.hasMoreElements()) { String name = (String)ee2.nextElement(); Object object = request.getAttribute(name); String className = object == null ? null : object.getClass().getName(); dbmd(name + of class:+ className); } dbmd(printRequestAttributeNames: for caller: + caller + - end); } //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - public static void printRequestParameters(String caller, HttpServletRequest request) { Enumeration ee5 = request.getParameterNames(); dbmd(printRequestParameters: for caller: + caller + - start...); while (ee5.hasMoreElements()) { String name = (String)ee5.nextElement(); String[] values = request.getParameterValues(name); String print = name: + name + value(s): ; for (int ii5 = 0; ii5 values.length; ii5++) { print += values[ii5]; if (ii5 values.length - 1) { print += , ; } } dbmd(print); } dbmd(printRequestParameters: for caller: + caller + - end); } == --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, sorry that I didn't mention it :) The error is that my form (which normally should have a scope session) is null ! so, when I run the app, it throws a java.lang.NullException, because I try to use sdf which is null (that's why I made a test to see if sdf == null, in that case my mapping returns an error page) To summarize, the problem isn't that I have wrong values, but that my form seems to not have a scope session (although it does have the mention session in the struts-config.xml) Thanx for your answer and sorry that I wasn't clear enough. Friendly Regards, Slimane At 01:42 13/03/2002 -0800, you wrote: it doesn't work anymore what's the exact problem, exception or form there but values not set as expected or what? If you create a constructor for your form print your form variable (ie' 'this' in it ( in the reset method too) you'll be able to make sure you only have 1 version of the form that you are 'talking' to the one you think you are. --- Slimane Zouggari [EMAIL PROTECTED] wrote: Hi, I have defined in my struts-config.xml an ActionForm with a scope session. Here's the struts-config code: actionpath=/searchbydate type=be.stluc.info.struts.SearchByDateAction name=searchbydateform scope=session forward name=successProject path=/projectdetails.do / forward name=successParticipant path=/participantdetails.do / forward name=successAllProject path=/allprojectdetails.do / forward name=successAllParticipant path=/allparticipantdetails.do /
Re: amount of data stored in session
Hopefully some-one has some better guidelines (not me!). Best I know is... 1 - Does anyone know how big is the session storage used internally by the server? Any thing you add is additional % that. 2 - I guess the more expensive your web-server the more efficient it's storage management would be. Ditto more expensive hardware. 3 - I'd expect these to be constantly improving. 4 - You'd have to bench mark your own configuration. 5 - If you are on Websphere on OS/390 storage should be effectively infinite free - so no worries!! --- [EMAIL PROTECTED] wrote: Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations. = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
File Upload and MultipartRequestWrapper
Hi, I'm using the latest nightly build from struts (1.1) and I'm experiencing some issues with file upload. The validation of the form performs well, but when the forward is called to display the next page, I've got the following exception. java.lang.ClassCastException: org.apache.struts.upload.MultipartRequestWrapper at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatch erImpl.java:172) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher Impl.java:162) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.jav a:970) at org.apache.struts.action.RequestProcessor.processActionForward(RequestPr ocessor.java:404) at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java: 269) at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1106) at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:468) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav a:806) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:752) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H ttpConnectionHandler.java:213) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416 ) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:50 1) at java.lang.Thread.run(Thread.java:484) I searched the archives but it seems that problem already appeared with the beta versions of struts 1.0. But it was more than one year ago! I have the latest versions of Xerces and Xalan... Everything but the file upload is working well. I cannot switch back to Struts 1.0 because of the nested behaviours that are essential for my application. Does anybody manage to have the file upload working with struts 1.1? Any idea to make it work? Thx Yannick
RE: Need help with JspException: Missing message for key login.ti tle
1 - does anything get data from ApplicationResources successfully? 2 - Try rename struts.jar on web-inf/lib re-start (just to prove there is no other version - or even unzipped struts class files somewhere in the class pth). 3 - reboot if on windows. (you have to it's traditional really does produce a miracle sometimes!). 4 - I am clutching at straws now!! --- [EMAIL PROTECTED] wrote: Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject: Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entitynamed above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this informationis prohibited. If you have received this electronic message in error, please notify us by telephone or email (to the numbers or address above) immediately. -- To unsubscribe, e-mail: mailto:struts-user- [EMAIL PROTECTED]For additional commands, e-mail: mailto:[EMAIL PROTECTED] **Disclaimer Information contained in this E-MAIL being proprietary to Wipro Limited is 'privileged' and 'confidential' and intended for use only by the individual or entity to which it is addressed. You are notified that any use, copying or dissemination of the information contained in the E-MAIL in any manner whatsoever is strictly prohibited.
RE: Help with Oracle dates from Secs passed since 1970
Hi, I tried the code below and it generated a date of 21-Sep-2001 (if thats the wrong date, I wouldn't bother reading any further!!) long secs = 1001091454; Calendar dtDate = Calendar.getInstance(); dtDate.setTime (new Date(secs*1000)); java.sql.Date newDate = new java.sql.Date(dtDate.getTime().getTime()); Les -Original Message- From: SUPRIYA MISRA [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 14:58 To: [EMAIL PROTECTED] Subject: Help with Oracle dates from Secs passed since 1970 If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: the best way to log action hits
Give us code for being thread safe then - i always avoided that stuff! My suggestions:- If voumes are low - use Log4J or similar - minimal work If you have a really fast database do it from a normal class, key DB table on the URL - the database locking will take care of concurrent access issues. good old database... If you have high volumes. 1 - do it in a small singleton class so synchronized code is quick. 2 - don't write output for every hit logged. Save data in an arraylist or if many pages (so it's big) an HaspMap. Write data to disk every 5 minutes or after every 50 messages logged (which ever happens 1st) - both these numbers being parms, so you can tune switch off the logging. I'd guess there'd be some code for this somewhere on the internet.. hope that helps.. --- Galbreath, Mark [EMAIL PROTECTED] wrote: Just create a thread-safe counter in the constructor and write it to a textfile. Mark -Original Message- From: Caoilte O'Connor [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 1:21 PM To: [EMAIL PROTECTED] Subject: the best way to log action hits Hi, I need to change my webapp to log the number of hits certain actions get and from which session etc etc. Can anyone point me towards the right way to look at doing this. Ideally I would use Log4J or something similar, but I'm a bit worried about having to parse lots of large text files every time my boss wants a gander (especially if he insists on having it done as a jsp page). I know this isn't strictly struts related, but any stabs at how other people have done *in their struts app* appreciated, Caoilte -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Why no struts.jar on the classpath?
Yeah - MarkG we're becoming dependant on you. Make sure you don't take fridays off! Perhaps people on this list will get really annoyed if we start having fun on other days of the week. Personally I reckon anyone who delivers good replies deserves some play-time. Especially since the standard is good (of the jokes I mean - I'm too inexperienced to speak for Marks replies!). --- Chappell, Simon P [EMAIL PROTECTED] wrote: True, but I NEED a good laugh on Fridays! :-) Simon -Original Message- From: MARK NICHOLS [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 12:36 PM To: [EMAIL PROTECTED] Subject: RE: Why no struts.jar on the classpath? Who cares! A good chuckle on Tuesday is better than a delayed laugh on Friday. /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/12/02 11:24AM It's not Friday yet! :-) -Original Message- From: Galbreath, Mark [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 11:17 AM To: 'Struts Users Mailing List' Subject: RE: Why no struts.jar on the classpath? Struts is actually a virus, though the delivery is a bit low-tech. Mark -Original Message- From: Chappell, Simon P [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 12:15 PM To: Struts mailing list (E-mail) Subject: Why no struts.jar on the classpath? I want to start out by saying that I have read the fine manual and realise that the struts FAQ says that the struts.jar must not be placed on the application server's CLASSPATH. My question to this list is why is this the case? I have a build manager who very much wants only a single instance of any jar file to exist on a server and they are asking why I am talking about putting multiples of the same file on their machine? Simon - Simon P. Chappell [EMAIL PROTECTED] Java Programming Specialist www.landsend.com Lands' End, Inc. (608) 935-4526 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:struts-user-[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:struts-user-[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Help with Oracle dates from Secs passed since 1970
Worked Great --Had to make sure the variable was a Long. Thanks import java.util.*; public class dated{ public static void main (String args[]){ Date d=new Date(1001091454*1000L); System.out.println(d); } From: Robert Nocera [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Subject: RE: Help with Oracle dates from Secs passed since 1970 Date: Wed, 13 Mar 2002 10:26:04 -0500 You can just convert seconds into milliseconds (*1000) and then use java.util.Date(milliseconds) to get your date which is Sep 21, 12:57:34 EDT 2001. Robert Nocera New England Open Solutions www.neosllc.com You supply the vision, we'll do the rest. -Original Message- From: SUPRIYA MISRA [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 9:58 AM To: [EMAIL PROTECTED] Subject: Help with Oracle dates from Secs passed since 1970 If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Chat with friends online, try MSN Messenger: http://messenger.msn.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Help with Oracle dates from Secs passed since 1970
I got the same .Thanks import java.util.*; public class dated{ public static void main (String args[]){ Date d=new Date(1001091454*1000L); System.out.println(d); } From: Wilson, Les J SI-FSIA [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Subject: RE: Help with Oracle dates from Secs passed since 1970 Date: Wed, 13 Mar 2002 17:19:54 +0100 Hi, I tried the code below and it generated a date of 21-Sep-2001 (if thats the wrong date, I wouldn't bother reading any further!!) long secs = 1001091454; Calendar dtDate = Calendar.getInstance(); dtDate.setTime (new Date(secs*1000)); java.sql.Date newDate = new java.sql.Date(dtDate.getTime().getTime()); Les -Original Message- From: SUPRIYA MISRA [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 14:58 To: [EMAIL PROTECTED] Subject: Help with Oracle dates from Secs passed since 1970 If anyone has a ready made solution to convert an UNIX TIME of seconds passed 1970 into java or oracle dates, please help. The number I get is 1001091454 which seconds passed since Jan 1st 1970. This needs to be converted to a valid oracle date. The answer will be a date in 2001. _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: JavaScript problem. please help me.
script if(navigator.appName ==Microsoft Internet Explorer) { blah blah } else if(navigator.appName ==Netscape) { blah blah } /scipt From: Cyber Sagar [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Subject: JavaScript problem. please help me. Date: Thu, 14 Mar 2002 00:46:47 +0900 Dear friends, I have a strange problem. please help me I have to execute 2 scripting files in a html page (One is compatible for Internet explorer and anotherone is for netscape) ie.js netscape.js how can i call these 2 scripts in my html file to make compatible for both IE and Netscape. I have to use only one html file to run these scripts in their respective browsers My code in html page is like this.. (menu.html) !--First script for IE-- script language=JavaScript src=ie.js /script script language=JavaScript new menu (MENU_ITEMS, MENU_POS1, MENU_STYLES1); /script !--Second script for NetScript-- script language=JavaScript src=netscape.js /script Body leftmargin=0 rightmargin=0 topmargin=0 marginwidth=0 marginheight=0 onLoad=writeMenus() == end == if i execute these scripts individually, these are working. please help me how can i execute netscape.js in netscape browser and ie.js in internet explorer, with this single html file. Your kind cooperation would be greatly appreciated. Thanks in advance. Yours Sagar winmail.dat -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
FW: Tiles and struts action
-Original Message- From: Hill, Donald Sent: Tuesday, March 12, 2002 12:44 PM To: 'Jakarta Tag Libraries Users List' (E-mail) Subject: Tiles and struts action I am trying to use a struts action in a tile definition, something like this. definition name=site.mainLayout path=/layouts/classicLayout.jsp put name=title value=Tiles Blank Site / put name=header value=/tiles/common/header.jsp / put name=menu value=site.menu.bar / put name=footer value=/tiles/common/footer.jsp / put name=body value=/tiles/body.jsp / /definition definition name=site.index.page extends=site.mainLayout put name=title value=Tiles Blank Site Index / put name=body value=jobList.do / /definition I always get a Response has been committed on the template page. Is there a trick to using a struts action in tiles or template tags that I am missing. -Don-
RE: Need help with JspException: Missing message for key login.ti tle
Thanks but I've given up! I don't care much for i18n at present so have abandoned the .properties file and resorted to hardcoding. Mind you - I do like how you can set the errors.header and footer. I will need that in the future I think. But I now have more problems (which I wont bother you with!). I'm going to make a fresh start and take each problem as it arises. Cos there's lots of stuff that I cant get my head around with any confidence - like the struts-config.xml file! Cheers. You can release those straws now =OD Lindsay -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 16:17 To: Struts Users Mailing List Subject:RE: Need help with JspException: Missing message for key login.ti tle 1 - does anything get data from ApplicationResources successfully? 2 - Try rename struts.jar on web-inf/lib re-start (just to prove there is no other version - or even unzipped struts class files somewhere in the class pth). 3 - reboot if on windows. (you have to it's traditional really does produce a miracle sometimes!). 4 - I am clutching at straws now!! --- [EMAIL PROTECTED] wrote: Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject: Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or confidential. The information is intended to be for the use of the individual(s) or entitynamed above. If you are not the intended recipient be aware that any disclosure, copying, distribution or use of the contents of this informationis prohibited. If you have received this electronic message in error, please
RE: Need help with JspException: Missing message for key login.ti tle
good attitide - it takes hero to run away from a problem! It can be hard going learning struts - nothing wrong with reducing your field of focus for a bit. --- [EMAIL PROTECTED] wrote: Thanks but I've given up! I don't care much for i18n at present so have abandoned the .properties file and resorted to hardcoding. Mind you - I do like how you can set the errors.header and footer. I will need that in the future I think. But I now have more problems (which I wont bother you with!). I'm going to make a fresh start and take each problem as it arises. Cos there's lots of stuff that I cant get my head around with any confidence - like the struts-config.xml file! Cheers. You can release those straws now =OD Lindsay -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 16:17 To: Struts Users Mailing List Subject: RE: Need help with JspException: Missing message for key login.ti tle 1 - does anything get data from ApplicationResources successfully? 2 - Try rename struts.jar on web-inf/lib re-start (just to prove there is no other version - or even unzipped struts class files somewhere in the class pth). 3 - reboot if on windows. (you have to it's traditional really does produce a miracle sometimes!). 4 - I am clutching at straws now!! --- [EMAIL PROTECTED] wrote: Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject:Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a trademark of British Telecommunications plc Registered office: 81 Newgate Street London EC1A 7AJ Registered in England no. 180 This electronic message contains information from British Telecommunications plc which may be privileged or
Perhaps TABOO Question, how to convert struts apps to non-struts
A co-worker and I were talking about this yesterday and I was curious of the following Seems like in order to develop a struts application, you'll have to pay for a private JVM instance so you can start and stop the tomcat or other JSP engine so that it can re-read the config.xml files Question 1: Any plans for struts to change in the future where you can dynamically add new actions and forwards without having to stop and re-start the web-server? I would guess (although I could be wrong) that this would be pretty easy to do within struts in the future?I assume struts is loading the config files in a DOM.Adding a new servlet within struts to reload the config files and update the DOM does not seem like it would be that difficult... Question 2: Supposing I wrote this app in struts and I could not find a sponser to pay the $50 per month fees to host a web-site...Well, I could reconvert the apps to a non-struts approach and then pay only $10 per month (because I would no longer need to start/stop the web-server and would only need to dump updated JSP's and such) Is there a document/technique/pattern/advice on the best way to convert existing struts applications to non-struts? I know that putting javabeans back into the JSP files would be a royal pain but if it would save $40 per month, it may be the best way to go :-) thanks, Theron -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Please help - String Indexed Properties
What i want to do is someting like: html:text name=contact_record property=(nickmane) / were contact_record reference one instance of a java.util.Map stored at request scope and nickmane is one key in this map. Does any body knows how to do this. Thanks, Oscar. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Nested Iterates...
Though unconventional but should work: % String itemTestValue= items[ + index + ].tests[ + index2 + ].value; % html:radio name=accountForm property=%=itemTestValue%/ -Original Message- From: Marcelo Caldas [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 9:26 AM To: Struts Mailing List Subject: Nested Iterates... Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: No getter - method order bug?
Keith, I suspect its more like if you overload you must overload both get and set.. eg.. if it takes an int there should be one that returns an int?.. Actually this all falls down when you consider properties of arrays.. you can return the whole array or one item.. but then the pattern is to have a get which takes an int and returns an object.. Thanks for your input.. I think I Better be more rigorous in my namint! Jon keithBacon wrote: Hi Jon, Good debugging! I'd like to see some clear rules about struts bean properties, so here's my attempt. (Not having read the bean spec very carefully!). 1 - If you want something treated as a property you must have get set methods even if you won't call them both (from bean spec). 2 - Declare the get set methods together (not necessary but good standard) most people do get before the set. 3 - If you overload the methods keep the matched pairs together. This is alarmimg. I figure if if follow these rules I won't hit any problems. It seems you've discovered that it's dangerous to overload methods that are properties. Has some-one got the time to get to the bottom of this? cheers - Keith. --- Jon Ferguson [EMAIL PROTECTED] wrote: Hey guys, I've finally managed to get this to work.. I thought it would be a classpath prob.. but looks a bit more insidious. In my CategoryWrapper class I actually had three relevant methods: public void setMapping(int index) public void setMapping(Map) public Map getMapping() The first is only used for setting things up explicitly... However because it came before the others struts expects there to be a public int getMapping() method. Even though the one requred for the jsp is available. If I move Map getMapping() above the other two in my source code this works. Java does not guarrantee order when listing methods with getDeclaredMethods() so I suspect the logic:iterate tag is not testing the methods correctly? Any other takes on this? I realise I should probably change the name of the first method to something like initializeMapping(int index) but it doesn't seem like it should fail.. Especially since this is likely to be random. Cheers, Jon Jon Ferguson wrote: Hey guys, anybody see this?? I've had the particular exception before but it's always been apparent what it was [eg. me :-) ]. I'm developing on Linux and Windows 2k. I've built a struts/tiles app that works flawlessly under my linux setup but when I serve it from my Windows 2k box I'm getting : No getter method for property mapping of bean category when my jsp is hit. The offending code uses a logic:iterate as follows: logic:iterate id=category type=uk.co.omegasoftware.util.struts.CategoryWrapper name=itemListForm property=categoryWrappers tr td html:link page=/inventory.do name=category property=mapping bean:write name=category property=name filter=true/ /html:link /td /tr /logic:iterate the CategoryWrapper class Does have the appropriate accessors: ... public void setMapping(Map map) { mapping = map; } public Map getMapping() { return mapping; } ... In both cases I'm using release versions of struts. I've tried 1.0: 1.0.1 and 1.0.2 I'm running on Tomcat 4.0-b6 on my Linux box.. I've tried: Tomcat 4.0.1, 3.2.3, and 4.0 on my Windows box. I'm using JDK 1.4.0-beta on linux I've tried JDK 1.3.1, 1.4.0-beta and 1.4.0-beta3 on windows Any ideas?? Thanks, Jon Part 1.2Type: Plain Text (text/plain) -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: dynamicly set an attribute of tags
Louis, I got the following error: An error occurred between lines: 46 and 47 in the jsp file: /WEB-INF/jsp/reg/RegForm.jsp Generated servlet error: C:\tomcat\work\localhost\test\WEB-INF\jsp\reg\RegForm$jsp.java:263: Method isReadOnly() not found in class java.lang.Object. _jspx_th_html_text_1.setReadonly( reg.isReadOnly() ); my code: bean:define id=reg name=reg.form.RegForm / html:html ... html:text property=name size=40 maxlength=40 readonly=%= reg.isReadOnly() % / What is wrong? From: Louis Leung [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: dynamicly set an attribute of tags Date: Tue, 12 Mar 2002 16:14:31 -0500 you can't do that, because your jsp page won't know where to find that function. if, in your case, you want to call a form's function, then you have to store the form in some scope, then use bean:define to get the form bean in your jsp, then you can call the form's function freely yanming lu wrote: I got error: Method isReadOnly() not found in class org.apache.jsp.RegForm$jsp. when I define isReadOnly() function the the form and used in the tag: html:text ... readonly=%=isReadOnly()% / Why? From: Louis Leung [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: dynamicly set an attribute of tags Date: Tue, 12 Mar 2002 14:51:11 -0500 you can define whether an attribute is a RTExpression (runtime expression) or not. for many of the struts tags, the attributes value can be of a RTExpression. so for your case, you are certainly legal to do something like html:text ... readonly=%=giveMeTrueOrFalse()%/ or any scriplet you wanna put yanming lu wrote: Is there any way in the struts to dynamically set an attribute? Example: html:text ... readonly=true.../ For this tag, can we somehow to set readonly to true sometimes to false based on certian conditions? _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Perhaps TABOO Question, how to convert struts apps to non-struts
Your assumptions are most likely wrong. Whether or not your Servlet container supports hot-redeploy is a general question, and not at all specific to Struts. Therefore, the question of whether to strip out Struts from your application shouldn't even be on the table with repsect to your concerns. I use Tomcat 4.0 as my production server. It supports hot-redeploy by way of the manager reload command, which I can do remotely. As far as I can tell, this only causes a momentary lapse of responsiveness for the one web-app I am redeploying, and the rest of my webapps stay running just fine. No stopping and starting of the entire container is required. With this mechanism, I can change mappings in struts-config.xml, add new Actions, update existing classes, etc., all on-the-fly. The only thing it doesn't do, is reload the web.xml file, which, luckily, changes very infrequently (as opposed to struts-config.xml which changes often). Bryan On Wed, 2002-03-13 at 10:17, [EMAIL PROTECTED] wrote: A co-worker and I were talking about this yesterday and I was curious of the following Seems like in order to develop a struts application, you'll have to pay for a private JVM instance so you can start and stop the tomcat or other JSP engine so that it can re-read the config.xml files Question 1: Any plans for struts to change in the future where you can dynamically add new actions and forwards without having to stop and re-start the web-server? I would guess (although I could be wrong) that this would be pretty easy to do within struts in the future?I assume struts is loading the config files in a DOM.Adding a new servlet within struts to reload the config files and update the DOM does not seem like it would be that difficult... Question 2: Supposing I wrote this app in struts and I could not find a sponser to pay the $50 per month fees to host a web-site...Well, I could reconvert the apps to a non-struts approach and then pay only $10 per month (because I would no longer need to start/stop the web-server and would only need to dump updated JSP's and such) Is there a document/technique/pattern/advice on the best way to convert existing struts applications to non-struts? I know that putting javabeans back into the JSP files would be a royal pain but if it would save $40 per month, it may be the best way to go :-) thanks, Theron -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Defining a forward path- not to a JSP, but to another Action
Hi In the examples I've seen - any forwards that are defined (whether global-forwards or action-specific) seem to point to JSP pages, i.e. global-forwards forward name=login path=/login.jsp/ forward name=success path=/home.jsp/ /global-forwards However I'd like for my user to login (handled by LoginAction) and then not just be sent straight to home.jsp. Instead, I'd like to forward to HomeAction which will prepare the necessary beans for use by home.jsp. How do I go about defining this in structs-config.xml? I'm a bit lost because I keep seeing elements called path but some look like /login.jsp and some look like /login. Why is this? Can you put /home.do as a forward path and it will forward to HomeAction? Or is this done simply by putting /home as the forward path. I'm sure this is very simple, but I really need to figure it out before my boss realises how little progress I've made this week! =o( Thanks. Lindsay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: amount of data stored in session
If you want to scale your application servers horizontally then you will need to keep your session size below about 4k. After 4k the sessions start to become to much to manage across servers and the session traffic between servers becomes a huge performance hit. dave -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:07 AM To: Struts Users Mailing List Subject: Re: amount of data stored in session Hopefully some-one has some better guidelines (not me!). Best I know is... 1 - Does anyone know how big is the session storage used internally by the server? Any thing you add is additional % that. 2 - I guess the more expensive your web-server the more efficient it's storage management would be. Ditto more expensive hardware. 3 - I'd expect these to be constantly improving. 4 - You'd have to bench mark your own configuration. 5 - If you are on Websphere on OS/390 storage should be effectively infinite free - so no worries!! --- [EMAIL PROTECTED] wrote: Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations. = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
How to use XML and XSL with Struts?
Subject: How to use XML and XSL with Struts? From: jcorey [EMAIL PROTECTED] === In my action I parse an xml document. I find the section of the xml data I want to display. Then I put a Node in the request and forward to a view jsp. The view jsp transforms the node object and puts the result in the response output stream. Is there a better way? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: amount of data stored in session
Along these lines, is there a simple way of determining the size of a user session at runtime? Is it as simple as a bit of code that will serialize to a temporary byte array and read the size? Has any one tried anything like this? Thanks in advance. Dave J Dandeneau [EMAIL PROTECTED] on 03/13/2002 11:37:10 AM Please respond to Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] cc: Subject: RE: amount of data stored in session If you want to scale your application servers horizontally then you will need to keep your session size below about 4k. After 4k the sessions start to become to much to manage across servers and the session traffic between servers becomes a huge performance hit. dave -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:07 AM To: Struts Users Mailing List Subject: Re: amount of data stored in session Hopefully some-one has some better guidelines (not me!). Best I know is... 1 - Does anyone know how big is the session storage used internally by the server? Any thing you add is additional % that. 2 - I guess the more expensive your web-server the more efficient it's storage management would be. Ditto more expensive hardware. 3 - I'd expect these to be constantly improving. 4 - You'd have to bench mark your own configuration. 5 - If you are on Websphere on OS/390 storage should be effectively infinite free - so no worries!! --- [EMAIL PROTECTED] wrote: Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations. = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
calling processActionForward from processesPreprocess in struts 1.0.2 timeout checking
http://www.mail-archive.com/struts-user@jakarta.apache.org/msg15542.html suggests calling processActionForward from unauthenticatedUser, which is called from processesPreprocess, to handle timout checking. But in the stable release processActionForward needs an ActionMapping parm. So I change the example code to this: private void unauthenticatedUser( HttpServletResponse iResponse, HttpServletRequest iRequest, String iRequestedPage) throws IOException, ServletException { HttpSession session = iRequest.getSession(); ActionErrors errors = new ActionErrors(); // redirect to the login servlet (passing parameter) String path = processPath(iRequest); this.log( User is not logged on in session + session.getId()); /*errors.add(ActionErrors.GLOBAL_ERROR, new ActionError(error.notloggedin)); saveErrors(iRequest, errors);*/ ActionForward logonForward = findForward(logon); ActionForward forward = new ActionForward(logonForward.getPath(), true); //forward.setPath(forward.getPath() + ?page= + iRequestedPage); processForward(processMapping(path,iRequest), iRequest, iResponse); } This function is being called when a timout occurs, but the forward to my logon page never happens. I just get a plain white screen. (The address bar shows me the name of last screen I was on.) -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: How to use XML and XSL with Struts?
Try out STXX (http://www.oroad.com/opencode/index.html). It handles XML and XSLT transforms for you at the Action level. It is currently at .9 release and I'm helping Jeff (the author of STXX) with a few extras for a 1.0 release. - Robert -Original Message- From: Struts Newsgroup [mailto:@[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:40 AM To: [EMAIL PROTECTED] Subject: How to use XML and XSL with Struts? Subject: How to use XML and XSL with Struts? From: jcorey [EMAIL PROTECTED] === In my action I parse an xml document. I find the section of the xml data I want to display. Then I put a Node in the request and forward to a view jsp. The view jsp transforms the node object and puts the result in the response output stream. Is there a better way? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Defining a forward path- not to a JSP, but to another Action
Piece of cake. You can define forwards that point to actions. The syntax below defines a forward to an action named 'myaction' defined in your struts-config.xml file. forward name=someforward path=/myaction.do/ I haven't done it, but I think you can do the same thing by creating an ActionForward with /myaction.do and returning that from your Action class. I've been using the first approach for a while and it works fine. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 12:37 PM To: [EMAIL PROTECTED] Subject: Defining a forward path- not to a JSP, but to another Action Hi In the examples I've seen - any forwards that are defined (whether global-forwards or action-specific) seem to point to JSP pages, i.e. global-forwards forward name=login path=/login.jsp/ forward name=success path=/home.jsp/ /global-forwards However I'd like for my user to login (handled by LoginAction) and then not just be sent straight to home.jsp. Instead, I'd like to forward to HomeAction which will prepare the necessary beans for use by home.jsp. How do I go about defining this in structs-config.xml? I'm a bit lost because I keep seeing elements called path but some look like /login.jsp and some look like /login. Why is this? Can you put /home.do as a forward path and it will forward to HomeAction? Or is this done simply by putting /home as the forward path. I'm sure this is very simple, but I really need to figure it out before my boss realises how little progress I've made this week! =o( Thanks. Lindsay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: Need help with JspException: Missing message for key login.ti tle
Run away! Run away! -Arthur, King of the Brits -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:45 AM To: Struts Users Mailing List Subject: RE: Need help with JspException: Missing message for key login.ti tle good attitide - it takes hero to run away from a problem! It can be hard going learning struts - nothing wrong with reducing your field of focus for a bit. --- [EMAIL PROTECTED] wrote: Thanks but I've given up! I don't care much for i18n at present so have abandoned the .properties file and resorted to hardcoding. Mind you - I do like how you can set the errors.header and footer. I will need that in the future I think. But I now have more problems (which I wont bother you with!). I'm going to make a fresh start and take each problem as it arises. Cos there's lots of stuff that I cant get my head around with any confidence - like the struts-config.xml file! Cheers. You can release those straws now =OD Lindsay -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 16:17 To: Struts Users Mailing List Subject: RE: Need help with JspException: Missing message for key login.ti tle 1 - does anything get data from ApplicationResources successfully? 2 - Try rename struts.jar on web-inf/lib re-start (just to prove there is no other version - or even unzipped struts class files somewhere in the class pth). 3 - reboot if on windows. (you have to it's traditional really does produce a miracle sometimes!). 4 - I am clutching at straws now!! --- [EMAIL PROTECTED] wrote: Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject:Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks for any input. Lindsay Lindsay Hamoudi Web Application Developer BTexact Technologies e-mail: [EMAIL PROTECTED] tel: (+44) (0)1473 605491 mobile: (+44) (0)7985 114296 Orion Building (B62-MH), PostPoint 12, Adastral Park, Martlesham, IpswichIP5 3RE, UK BTexact Technologies is a
Re: dynamicly set an attribute of tags
try bean:define id=reg name=formName type=reg.form.RegForm/ where formName is the name u defined in the struts-config.xml yanming lu wrote: Louis, I got the following error: An error occurred between lines: 46 and 47 in the jsp file: /WEB-INF/jsp/reg/RegForm.jsp Generated servlet error: C:\tomcat\work\localhost\test\WEB-INF\jsp\reg\RegForm$jsp.java:263: Method isReadOnly() not found in class java.lang.Object. _jspx_th_html_text_1.setReadonly( reg.isReadOnly() ); my code: bean:define id=reg name=reg.form.RegForm / html:html ... html:text property=name size=40 maxlength=40 readonly=%= reg.isReadOnly() % / What is wrong? From: Louis Leung [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: dynamicly set an attribute of tags Date: Tue, 12 Mar 2002 16:14:31 -0500 you can't do that, because your jsp page won't know where to find that function. if, in your case, you want to call a form's function, then you have to store the form in some scope, then use bean:define to get the form bean in your jsp, then you can call the form's function freely yanming lu wrote: I got error: Method isReadOnly() not found in class org.apache.jsp.RegForm$jsp. when I define isReadOnly() function the the form and used in the tag: html:text ... readonly=%=isReadOnly()% / Why? From: Louis Leung [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: dynamicly set an attribute of tags Date: Tue, 12 Mar 2002 14:51:11 -0500 you can define whether an attribute is a RTExpression (runtime expression) or not. for many of the struts tags, the attributes value can be of a RTExpression. so for your case, you are certainly legal to do something like html:text ... readonly=%=giveMeTrueOrFalse()%/ or any scriplet you wanna put yanming lu wrote: Is there any way in the struts to dynamically set an attribute? Example: html:text ... readonly=true.../ For this tag, can we somehow to set readonly to true sometimes to false based on certian conditions? _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Join the worlds largest e-mail service with MSN Hotmail. http://www.hotmail.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] _ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: amount of data stored in session
IBM has published some Best Practices material that I consider excellent guidance. Although some of the material may be specific to WebSphere, the recommendations are likely relevant to most application servers. Here is the link to the specific best practice. Don't know if this will come across very well: http://www7b.boulder.ibm.com/webapp/dd/transform.wss?URL=/wsdd/library/bestp ractices/store_objects_in_httpsession.xmlxslURL=/wsdd/xsl/bestpractice.xsl Here is another link to the Best Practices Zone: http://www7b.boulder.ibm.com/wsdd/zones/bp/ Just hit the Retrieve button on the page and it will take you to a list of matching resources that will include Best Practice: Storing Objects in HTTP Sessions. Most (but not all) of the best practices in the zone were published some time ago in a whitepaper that you can find here: http://www-4.ibm.com/software/webservers/appserv/ws_bestpractices.pdf And I think the following is more or less a reprint of the specific practice: http://www.advisor.com/Articles.nsf/aid/GUNTH01 Best regards, Jim Cakalic -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 9:18 AM To: [EMAIL PROTECTED] Subject: amount of data stored in session Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations.
RE: amount of data stored in session
I prefer to use a profiler, but I had looked into writing a class that did just that, but could not find one that would give the exact size of the session object. The easiest way to do it with regular java objects is to create one, garbage collect, record available memory, null the object, garbage collect, re-record the available memory, and then compare the difference. Since the session object is still referenced by the container you can't use this method. This is described in a javaworld article (http://www.javaworld.com/gomail.cgi?id=783152). There may be some variation on this that could do it. Thanks, dave -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 12:42 PM To: Struts Users Mailing List Subject: RE: amount of data stored in session Along these lines, is there a simple way of determining the size of a user session at runtime? Is it as simple as a bit of code that will serialize to a temporary byte array and read the size? Has any one tried anything like this? Thanks in advance. Dave J Dandeneau [EMAIL PROTECTED] on 03/13/2002 11:37:10 AM Please respond to Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] cc: Subject: RE: amount of data stored in session If you want to scale your application servers horizontally then you will need to keep your session size below about 4k. After 4k the sessions start to become to much to manage across servers and the session traffic between servers becomes a huge performance hit. dave -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:07 AM To: Struts Users Mailing List Subject: Re: amount of data stored in session Hopefully some-one has some better guidelines (not me!). Best I know is... 1 - Does anyone know how big is the session storage used internally by the server? Any thing you add is additional % that. 2 - I guess the more expensive your web-server the more efficient it's storage management would be. Ditto more expensive hardware. 3 - I'd expect these to be constantly improving. 4 - You'd have to bench mark your own configuration. 5 - If you are on Websphere on OS/390 storage should be effectively infinite free - so no worries!! --- [EMAIL PROTECTED] wrote: Are there published guidelines as to the number and size of objects that are stored in the session? I've seen references to the importance of keeping session data to a minimum, but no concrete recommendations. = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: the best way to log action hits
Simple: int count; String path; public void init() throws ServletException { FileReader fr = null; BufferedReader br = null; String path = [path to counting file]; try{ fr = new FileReader( path); br = new BufferedReader( fr); String cnt = br.readLine(); count = Integer.parseInt( cnt); } catch( FileNotFoundException e){} catch( IOException e) {} catch( NumberFormatException e) {} finally { try { if( br !=) br.close(); } catch( IOException) {} } } public void doGet( HttpServletRequest req, HttpServletResponse res) { synchronized.this { count++; } } public void destroy { FileWriter fw = null; PrintWrite pw = null; try { fw = new FileWriter( path); pw = new PrintWriter( fw); pw.println( count); } catch( IOException e) {} finally { try { if( pw != null) pw.close(); } catch( IOException e) {} } } There ya go! Mark -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:30 AM Give us code for being thread safe then - i always avoided that stuff! --- Galbreath, Mark [EMAIL PROTECTED] wrote: Just create a thread-safe counter in the constructor and write it to a textfile. Mark -Original Message- From: Caoilte O'Connor [mailto:[EMAIL PROTECTED]] Sent: Tuesday, March 12, 2002 1:21 PM Hi, I need to change my webapp to log the number of hits certain actions get and from which session etc etc. Can anyone point me towards the right way to look at doing this. Ideally I would use Log4J or something similar, but I'm a bit worried about having to parse lots of large text files every time my boss wants a gander (especially if he insists on having it done as a jsp page). I know this isn't strictly struts related, but any stabs at how other people have done *in their struts app* appreciated, Caoilte -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Perhaps TABOO Question, how to convert struts apps to non-struts
Tomcat manager app is documented here: http://jakarta.apache.org/tomcat/tomcat-4.0-doc/manager-howto.html Personally, I don't know what are the current state-of-the-art best-practices for web hosting providers. However, I have to assume that they generally allow their customers to restart their web applications, without affecting their other customers' uptimes. Tomcat 4.x lets you start, stop, reload, deploy (from scratch), and undeploy web applications using the manager interface, all without affecting any other running web applications (and yes, they all share a single JVM). On Wed, 2002-03-13 at 11:27, [EMAIL PROTECTED] wrote: I'm curious.I did not know about the manager reload command. Where can I find out more about it? Also, if I went with a web-hosting service that had 1 and only 1 tomcat JVM instance, would the reload command be something the hosting site would allow me to run?Would the reload command affect all of the other folks using the same Tomcat JVM instance? If so, I would assume that the web-hosting service would not allow me to use the reload command and thus would still be stuck with the $50 per month private-jvm instance fee. thanks, Theron Bryan Field-Elliot To: Struts Users Mailing List bryan_lists@ne[EMAIL PROTECTED] tmeme.org cc: Subject: Re: Perhaps TABOO Question, how to convert struts 03/13/02 09:35 apps to non-struts AM Please respond to Struts Users Mailing List Your assumptions are most likely wrong. Whether or not your Servlet container supports hot-redeploy is a general question, and not at all specific to Struts. Therefore, the question of whether to strip out Struts from your application shouldn't even be on the table with repsect to your concerns. I use Tomcat 4.0 as my production server. It supports hot-redeploy by way of the manager reload command, which I can do remotely. As far as I can tell, this only causes a momentary lapse of responsiveness for the one web-app I am redeploying, and the rest of my webapps stay running just fine. No stopping and starting of the entire container is required. With this mechanism, I can change mappings in struts-config.xml, add new Actions, update existing classes, etc., all on-the-fly. The only thing it doesn't do, is reload the web.xml file, which, luckily, changes very infrequently (as opposed to struts-config.xml which changes often). Bryan On Wed, 2002-03-13 at 10:17, [EMAIL PROTECTED] wrote: A co-worker and I were talking about this yesterday and I was curious of the following Seems like in order to develop a struts application, you'll have to pay for a private JVM instance so you can start and stop the tomcat or other JSP engine so that it can re-read the config.xml files Question 1: Any plans for struts to change in the future where you can dynamically add new actions and forwards without having to stop and re-start the web-server? I would guess (although I could be wrong) that this would be pretty easy to do within struts in the future?I assume struts is loading the config files in a DOM.Adding a new servlet within struts to reload the config files and update the DOM does not seem like it would be that difficult... Question 2: Supposing I wrote this app in struts and I could not find a sponser to pay the $50 per month fees to host a web-site...Well, I could reconvert the apps to a non-struts approach and then pay only $10 per month (because I would no longer need to start/stop the web-server and would only need to dump updated JSP's and such) Is there a document/technique/pattern/advice on the best way to convert existing struts applications to non-struts? I know that putting javabeans back into the JSP files would be a
RE: Need help with JspException: Missing message for key login.ti tle
Well - I seem to have inadvertently fixed the problem! I really don't know what made the difference. Now for my next problem... -Original Message- From: Galbreath, Mark [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 18:01 To: 'Struts Users Mailing List' Subject:RE: Need help with JspException: Missing message for key login.ti tle Run away! Run away! -Arthur, King of the Brits -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:45 AM To: Struts Users Mailing List Subject: RE: Need help with JspException: Missing message for key login.ti tle good attitide - it takes hero to run away from a problem! It can be hard going learning struts - nothing wrong with reducing your field of focus for a bit. --- [EMAIL PROTECTED] wrote: Thanks but I've given up! I don't care much for i18n at present so have abandoned the .properties file and resorted to hardcoding. Mind you - I do like how you can set the errors.header and footer. I will need that in the future I think. But I now have more problems (which I wont bother you with!). I'm going to make a fresh start and take each problem as it arises. Cos there's lots of stuff that I cant get my head around with any confidence - like the struts-config.xml file! Cheers. You can release those straws now =OD Lindsay -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 16:17 To: Struts Users Mailing List Subject: RE: Need help with JspException: Missing message for key login.ti tle 1 - does anything get data from ApplicationResources successfully? 2 - Try rename struts.jar on web-inf/lib re-start (just to prove there is no other version - or even unzipped struts class files somewhere in the class pth). 3 - reboot if on windows. (you have to it's traditional really does produce a miracle sometimes!). 4 - I am clutching at straws now!! --- [EMAIL PROTECTED] wrote: Thanks for the suggestions, but still no change. I am using Tomcat-3.3 with Struts-1.0.2 on Windows-2000 Pro. Struts.jar is no longer in my system classpath and is only in web-inf/lib directory of my webapp. I have restarted the container, but still the same story. Any more suggestions. I'll try rebooting but I'm desperate now! Tomcat overrides the system classpath anyway does it not? -Original Message- From: keithBacon [mailto:[EMAIL PROTECTED]] Sent: 13 March 2002 13:51 To: Struts Users Mailing List Subject:Re: Need help with JspException: Missing message for key login.title not sure but might be one of those where your struts.jar is in the wrong place. Make sure it is in your web app's WEB-INF/lib nowhere else where the server could find it (ie. not on your system or server classpath). --- Alok Kumar [EMAIL PROTECTED] wrote: YOu should put one more line in Applicationproperties file that is login.title=some text ouyt here Alok - Original Message - From: [EMAIL PROTECTED] Date: Wednesday, March 13, 2002 4:24 pm Subject: Need help with JspException: Missing message for key login.title Hi everyone, I've just began using Struts this week and it seems very useful, but I am totally lost for ideas when it comes to this exception: Exception in R( /struts-SACT + /login.jsp + null) - javax.servlet.ServletException: Missing message for key login.title I have placed my ApplicationResources.properties in the /classes directoryand here's the relevant part of web.xml: servlet servlet-nameaction/servlet-name servlet- classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param . Here's my ApplicationResources.properties (it is very simple at present - which makes this error all the more annoying): error.username.required=Username is required error.password.required=Password is required error.database.unknown=Sorry, an unknown database error occurred errors.footer=/ulbr errors.header=h2font color=redValidation Error/font/h2You must correct the following error(s) before proceeding:ul login.title=SME Agent Creation Tool - User Login prompt.login.username=Username prompt.login.password=Password And here's a part of my login.jsp: %@ page language=java % %@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean % %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % html:html head titlebean:message key=login.title//title I heard that this is a common problem and that I should look at the mailing list archive, but I find no help there at all. Many thanks
More problems: No action instance for path /login could be create d...
Ok my login.jsp is loading fine, and the ActionForm (LoginForm) is working OK because error messages are being returned OK. But when I submit valid entries (i.e. when my Action class, LoginAction, should kick in) - I get this error message: Status code:500 request:R( /struts-SACT + /login.do + null) msg:No action instance for path /login could be created I'm assuming this is not a problem with my LoginAction class because it can't even create an instance. It must be something to do with the dreaded struts-config.xml file. Here's what I've got: struts-config !-- == Data Source Configuration === -- !-- == Form Bean Definitions === -- form-beans !-- Login form bean -- form-bean name=loginForm type=zeus.generator.web.model.LoginForm/ /form-beans !-- == Global Forward Definitions == -- global-forwards forward name=login path=/login.jsp/ forward name=success path=/home.do/ /global-forwards !-- == Action Mapping Definitions == -- action-mappings !-- Process a user login -- action path=/login type=zeus.generator.web.controller.LoginAction name=loginForm validate=true scope=request input=/login.jsp forward name=success path=/home.do/ /action !-- Process a request for home page-- action path=/home type=zeus.generator.web.controller.HomeAction forward name=success path=/home.jsp/ /action !-- The standard administrative actions available with Struts -- !-- These would be either omitted or protected by security -- !-- in a real application deployment -- ... Bla bla bla (I never touched these so they're OK) /action-mappings /struts-config My classes are in the correct packages - I know this (erm...) for definite. What ELSE could be causing this? Incidentally, the JSP form submits to /login using the html:form tag. Many many thanks if someone can help Lindsay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Defining a forward path- not to a JSP, but to anotherAction
I have done what you want. Here is a piece of my struts-config.xml: !-- Finish Reason Insert action -- action path=/finishReasonInsert type=vcm.vis.action.FinishReasonInsertAction name=finishReasonForm scope=session input=finishReasonInsert.jsp parameter=method forwardname=success path=/loadFinishReason.do/ forwardname=failure path=/finishReasonInsert.jsp/ /action The success path from finishReasonInsert (action) is the loadFinishReason (action). HTH, /\/\ark ___ - mark h. nichols - dhsv022 at dhs dot state dot il dot us The best laid plans o'mice and men gang aft aglay... -Robert Burns [EMAIL PROTECTED] 03/13/02 11:37AM Hi In the examples I've seen - any forwards that are defined (whether global-forwards or action-specific) seem to point to JSP pages, i.e. global-forwards forward name=login path=/login.jsp/ forward name=success path=/home.jsp/ /global-forwards However I'd like for my user to login (handled by LoginAction) and then not just be sent straight to home.jsp. Instead, I'd like to forward to HomeAction which will prepare the necessary beans for use by home.jsp. How do I go about defining this in structs-config.xml? I'm a bit lost because I keep seeing elements called path but some look like /login.jsp and some look like /login. Why is this? Can you put /home.do as a forward path and it will forward to HomeAction? Or is this done simply by putting /home as the forward path. I'm sure this is very simple, but I really need to figure it out before my boss realises how little progress I've made this week! =o( Thanks. Lindsay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Perhaps TABOO Question, how to convert struts apps to non-struts
My personal experience is that if you're writing the application in any form of tiered way (beans, classes, etc), only service providers that give you your own JVM instance are going to let you deploy those classes anyways (making the non-inclusion of Struts a moot point). I've found that every service provider that I've worked w/ or seen that provides a shared JVM won't allow you to deploy classes. In those situations I've had to write everything in JSP - SUCKS! - Original Message - From: [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 11:17 AM Subject: Perhaps TABOO Question, how to convert struts apps to non-struts A co-worker and I were talking about this yesterday and I was curious of the following Seems like in order to develop a struts application, you'll have to pay for a private JVM instance so you can start and stop the tomcat or other JSP engine so that it can re-read the config.xml files Question 1: Any plans for struts to change in the future where you can dynamically add new actions and forwards without having to stop and re-start the web-server? I would guess (although I could be wrong) that this would be pretty easy to do within struts in the future?I assume struts is loading the config files in a DOM.Adding a new servlet within struts to reload the config files and update the DOM does not seem like it would be that difficult... Question 2: Supposing I wrote this app in struts and I could not find a sponser to pay the $50 per month fees to host a web-site...Well, I could reconvert the apps to a non-struts approach and then pay only $10 per month (because I would no longer need to start/stop the web-server and would only need to dump updated JSP's and such) Is there a document/technique/pattern/advice on the best way to convert existing struts applications to non-struts? I know that putting javabeans back into the JSP files would be a royal pain but if it would save $40 per month, it may be the best way to go :-) thanks, Theron -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Activity
I've been noticing more activity on the list and was curious how many subscribers this list has grown to presently? -- Sandra -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: RE: How to use XML and XSL with Struts?
Hi! Do you know if STXX will find it's way into Struts standard distribution ? 13.03.2002 18:47:16, Robert [EMAIL PROTECTED] wrote: Try out STXX (http://www.oroad.com/opencode/index.html). It handles XML and XSLT transforms for you at the Action level. It is currently at .9 release and I'm helping Jeff (the author of STXX) with a few extras for a 1.0 release. - Robert -Original Message- From: Struts Newsgroup [mailto:@[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:40 AM To: [EMAIL PROTECTED] Subject: How to use XML and XSL with Struts? Subject: How to use XML and XSL with Struts? From: jcorey [EMAIL PROTECTED] === In my action I parse an xml document. I find the section of the xml data I want to display. Then I put a Node in the request and forward to a view jsp. The view jsp transforms the node object and puts the result in the response output stream. Is there a better way? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: RE: How to use XML and XSL with Struts?
Couldn't tell you as that's out of my hands :-) The feature that I'm adding is the ability to support static XML files. The current action uses dynamic XML files, generated in the action class. It stores the document (a JDom Document) in the request, and the servlet then transforms the document with a supplied XSL sheet. The .9 examples are really good and you should take a look at them. - Robert -Original Message- From: Gernot Koller [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 1:22 PM To: Struts Users Mailing List Subject: Re: RE: How to use XML and XSL with Struts? Hi! Do you know if STXX will find it's way into Struts standard distribution ? 13.03.2002 18:47:16, Robert [EMAIL PROTECTED] wrote: Try out STXX (http://www.oroad.com/opencode/index.html). It handles XML and XSLT transforms for you at the Action level. It is currently at .9 release and I'm helping Jeff (the author of STXX) with a few extras for a 1.0 release. - Robert -Original Message- From: Struts Newsgroup [mailto:@[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:40 AM To: [EMAIL PROTECTED] Subject: How to use XML and XSL with Struts? Subject: How to use XML and XSL with Struts? From: jcorey [EMAIL PROTECTED] === In my action I parse an xml document. I find the section of the xml data I want to display. Then I put a Node in the request and forward to a view jsp. The view jsp transforms the node object and puts the result in the response output stream. Is there a better way? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Nested Iterates...
Ok, I've got progress... I've downloaded the latest struts build wich contains the NESTED tags... I'm trying to use the nested:iterate and nested:radio, but I couldn'g get grip of everything from the docs that comes together... So if there's anyone out there that has used the nested tags properly I'll appreciate the help.. After, several tries, the best result I have is: nested:iterate id=items ... nested:itearate id=tests ... nested:root name=tests nested:iterate id=answer ... nested:radio name=answer ... /nested:iterate /nested:root /nested:iterate /nested:iterate It seems that it got almost right, but it looks like tests looses it's index providing a result: input type=radio name=tests[0].answer[0].responseID value=OK input type=radio name=tests[0].answer[0].responseID value=NOK input type=radio name=tests[1].answer[1].responseID value=OK input type=radio name=tests[1].answer[1].responseID value=NOK That is my first line on a table (All supposed to be based on tests[0] only... The second row is the one supposed to be tests[1], but instead it repeats the tests[0] and tests[1] the same way as the lines above... If I move the root to items, like: nested:iterate id=items ... nested:root name=items nested:itearate id=tests ... nested:iterate id=answer ... nested:radio name=answer ... /nested:iterate /nested:iterate /nested:root /nested:iterate It looks a little bit better, but items looses it's indexing as well with the same behavior as above for tests... Besides if tests works properly that is enought to identify my radio groups. While with the extra level for the items (output below), I don't know how the Actionform will behave... input type=radio name=items[0].tests[0].responses[0].responseID value=OK input type=radio name=items[0].tests[0].responses[0].responseID value=NOK input type=radio name=items[1].tests[0].responses[1].responseID value=OK input type=radio name=items[1].tests[0].responses[1].responseID value=NOK As you can see, on the above output everything was fine IF the items[x] doesn't print Thanks, Marcelo. On Wed, 13 Mar 2002 10:58:43 -0500 Olexander Rudyy [EMAIL PROTECTED] wrote: Look at http://www.keyboardmonkey.com/struts/index.html - Original Message - From: Marcelo Caldas [EMAIL PROTECTED] Newsgroups: Struts To: Struts Mailing List [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 4:25 PM Subject: Nested Iterates... Hi guys, I have a logic:iterate inside a logic:iterate tag in the following manner: logic:iterate id=items ... logic:iterate id=tests ... html:radio name=tests property=value indexed=true/ ... The problem is that the HTML being generated is like input type=radio name=tests[0].value when actually I want to group them as items as well, like: input type=radio name=items[0].tests[0].value Anyone knows how to have such output? thanks, Marcelo. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Perhaps TABOO Question, how to convert struts apps to non-struts
1 - http://myserver/my-web-app/admin/reload.do reloads ApplicationResources I think struts-config. If I haven't recompiled any classes it works for me. On Tomcat it goes wonky if I've re-compiled so I have to restart. This is if thoe entries for admin unctions are in your struts-config.xml. They can be copied from the struts-blank webapp. 2 - webappcabaret others (WantJava) effectively give you a safe JVM. They give you 1 web-app your own Servlet context so you are safe to deploy classes etc. Presumabaly with Unix security they can protect disk files outside you directory tree they must give each context it's own JVM - I get a feeling it might me a 'virtual' JVM. I recall they had the details on their site. You can no longer get this stuff free - but the rates aren't huge. I recall webappcabaret won't let a pool of people share a site - you have to each pay. I deployed a trial system on WantJava 18 months ago they were fine. This was servlets/jsp a JDBC database (Maybe oracle). Keith. --- John M. Corro [EMAIL PROTECTED] wrote: My personal experience is that if you're writing the application in any form of tiered way (beans, classes, etc), only service providers that give you your own JVM instance are going to let you deploy those classes anyways (making the non-inclusion of Struts a moot point). I've found that every service provider that I've worked w/ or seen that provides a shared JVM won't allow you to deploy classes. In those situations I've had to write everything in JSP - SUCKS! - Original Message - From: [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, March 13, 2002 11:17 AM Subject: Perhaps TABOO Question, how to convert struts apps to non-struts A co-worker and I were talking about this yesterday and I was curious of the following Seems like in order to develop a struts application, you'll have to pay for a private JVM instance so you can start and stop the tomcat or other JSP engine so that it can re-read the config.xml files Question 1: Any plans for struts to change in the future where you can dynamically add new actions and forwards without having to stop and re-start the web-server? I would guess (although I could be wrong) that this would be pretty easy to do within struts in the future?I assume struts is loading the config files in a DOM.Adding a new servlet within struts to reload the config files and update the DOM does not seem like it would be that difficult... Question 2: Supposing I wrote this app in struts and I could not find a sponser to pay the $50 per month fees to host a web-site...Well, I could reconvert the apps to a non-struts approach and then pay only $10 per month (because I would no longer need to start/stop the web-server and would only need to dump updated JSP's and such) Is there a document/technique/pattern/advice on the best way to convert existing struts applications to non-struts? I know that putting javabeans back into the JSP files would be a royal pain but if it would save $40 per month, it may be the best way to go :-) thanks, Theron -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] = ~~ Search the archive:- http://www.mail-archive.com/struts-user%40jakarta.apache.org/ ~~ Keith Bacon - Looking for struts work - South-East UK. phone UK 07960 011275 __ Do You Yahoo!? Try FREE Yahoo! Mail - the world's greatest free email! http://mail.yahoo.com/ -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
RE: More problems: No action instance for path /login could be create d...
Are you using a forward or action in your jsp? If using a forward you'll need an entry in global-forwards. If you're using an action in an html:form don't use .do -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 1:43 PM To: [EMAIL PROTECTED] Subject: More problems: No action instance for path /login could be create d... Ok my login.jsp is loading fine, and the ActionForm (LoginForm) is working OK because error messages are being returned OK. But when I submit valid entries (i.e. when my Action class, LoginAction, should kick in) - I get this error message: Status code:500 request:R( /struts-SACT + /login.do + null) msg:No action instance for path /login could be created I'm assuming this is not a problem with my LoginAction class because it can't even create an instance. It must be something to do with the dreaded struts-config.xml file. Here's what I've got: struts-config !-- == Data Source Configuration === -- !-- == Form Bean Definitions === -- form-beans !-- Login form bean -- form-bean name=loginForm type=zeus.generator.web.model.LoginForm/ /form-beans !-- == Global Forward Definitions == -- global-forwards forward name=login path=/login.jsp/ forward name=success path=/home.do/ /global-forwards !-- == Action Mapping Definitions == -- action-mappings !-- Process a user login -- action path=/login type=zeus.generator.web.controller.LoginAction name=loginForm validate=true scope=request input=/login.jsp forward name=success path=/home.do/ /action !-- Process a request for home page-- action path=/home type=zeus.generator.web.controller.HomeAction forward name=success path=/home.jsp/ /action !-- The standard administrative actions available with Struts -- !-- These would be either omitted or protected by security -- !-- in a real application deployment -- ... Bla bla bla (I never touched these so they're OK) /action-mappings /struts-config My classes are in the correct packages - I know this (erm...) for definite. What ELSE could be causing this? Incidentally, the JSP form submits to /login using the html:form tag. Many many thanks if someone can help Lindsay -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] This email and any files transmitted with it are confidential and are intended for the sole use of the individual to whom they are addressed. Black Box Corporation reserves the right to scan all e-mail traffic for restricted content and to monitor all e-mail in general. If you are not the intended recipient or you have received this email in error, any use, dissemination or forwarding of this email is strictly prohibited. If you have received this email in error, please notify the sender by replying to this email.
Re: RE: RE: How to use XML and XSL with Struts?
Haven't had a closer look to STXX yet. Already had finished my own XSLT-Servlet when I stumbled over STXX. My solution heavily relies on XSLT-Filter chaining to provide practicable solutions for i18n, etc. I didn't touch Struts though, as I know I won't be able to keep up as Struts envolves... But I will asap take a closer look to STXX. Gernot. 13.03.2002 20:20:40, Robert [EMAIL PROTECTED] wrote: Couldn't tell you as that's out of my hands :-) The feature that I'm adding is the ability to support static XML files. The current action uses dynamic XML files, generated in the action class. It stores the document (a JDom Document) in the request, and the servlet then transforms the document with a supplied XSL sheet. The .9 examples are really good and you should take a look at them. - Robert -Original Message- From: Gernot Koller [mailto:[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 1:22 PM To: Struts Users Mailing List Subject: Re: RE: How to use XML and XSL with Struts? Hi! Do you know if STXX will find it's way into Struts standard distribution ? 13.03.2002 18:47:16, Robert [EMAIL PROTECTED] wrote: Try out STXX (http://www.oroad.com/opencode/index.html). It handles XML and XSLT transforms for you at the Action level. It is currently at .9 release and I'm helping Jeff (the author of STXX) with a few extras for a 1.0 release. - Robert -Original Message- From: Struts Newsgroup [mailto:@[EMAIL PROTECTED]] Sent: Wednesday, March 13, 2002 11:40 AM To: [EMAIL PROTECTED] Subject: How to use XML and XSL with Struts? Subject: How to use XML and XSL with Struts? From: jcorey [EMAIL PROTECTED] === In my action I parse an xml document. I find the section of the xml data I want to display. Then I put a Node in the request and forward to a view jsp. The view jsp transforms the node object and puts the result in the response output stream. Is there a better way? -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Perhaps TABOO Question, how to convert struts apps to non-struts
On Wed, 2002-03-13 at 12:02, John M. Corro wrote: I've found that every service provider that I've worked w/ or seen that provides a shared JVM won't allow you to deploy classes. In those situations I've had to write everything in JSP - SUCKS! Of course that's silly, because JSP pages are basically classes anyway... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Activity
Subject: Re: Activity From: Jeff [EMAIL PROTECTED] === Sandra Cann [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED]... I've been noticing more activity on the list and was curious how many subscribers this list has grown to presently? -- Sandra -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] I don't know about everyone else, but the availability of the list via basebeans.com's NNTP server made a huge difference for me. I _HATE_ mailing lists with a passion, and like private newsfeeds a LOT better. Before, when the choice was to either lurk silently via the archive or get firehosed by endless incoming email, lurking definitely had its advantages... -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: FW: Config for WAS 3.5 on OS/390?
Just curious about several things on this setup. 1.Did you need a special patch level to make this work? We are at 3.5.3. 2. What JDK version are you using? We are using 1.3. 3. Which struts jar are you using? Is it the websphere specific version for NT? Or, is it normal version? Do you put it on your classpath? 4. Do you have the DTD's, struts-config_1_0.dtd, web-app_2_2.dtd, and web-app_2_3.dtd outside the jar file? Or did you keep them inside? We have ours outside and modified as the windows 2000 documentation mentioned. Reason I am asking is that I cannot get the action servlet to load. It is abending with the following: . Mar 13, 2002 15:36:18.066 PM Thread-1 ServletInstan X Uncaught init() exception thrown by servlet {0}: {1} action javax.servlet.ServletException: java.lang.ClassNotFoundException :at :com.ibm.servlet.engine.webapp.StrictServletInstance.doInit(t(ServletManager.java:637) :at :com.ibm.servlet.engine.webapp.StrictLifecycleServlet._init(StrictLifecycleServlet.java:136) :at :com.ibm.servlet.engine.webapp.PreInitializedServletState.init(StrictLifecycleServlet.java:236) :at :com.ibm.servlet.engine.webapp.StrictLifecycleServlet.init(StrictLifecycleServlet.java:102) :at com.ibm.servlet.engine.webapp.ServletInstance.init(ServletManager.java:301) :at javax.servlet.GenericServlet.init(GenericServlet.java:258) Steven Banks 368-0566 KASSON, STEVEN R (Steve), ALBAS [EMAIL PROTECTED] 03/11/02 05:28PM Hmm... I received a follow-up question on this topic, so I tried to find my posting from awhile back. I couldn't find it in the archives... so here it is again. Regards, -Steve To: [EMAIL PROTECTED] Subject: RE: Config for WAS 3.5 on OS/390? Hi All, Since I made my original post we've been able to get things running. Here are the details (I needed to write them up anyway). I'm sure it's not the only solution, but it's working! Any suggestions on the DTD validation are welcome... Regards, -Steve Configuring Struts 1.0 on WAS 3.5 for OS/390 Background Info: WAS for OS/390 strives to be compatible with the multi-platform releases of WAS, but it does have some differences. One big difference is the lack of the Administrator's Console. Instead it uses a set of properties files to configure the server and web applications. The following site has specific documentation; the Planning, Installing, and Using (PIU) document is the most useful. http://www-4.ibm.com/software/webservers/appserv/library_390.html There is a section in Chapter 3 of the PIU document which details how to convert a WAR file. We tried this on the struts-blank.war but were unable to get things working. But it was helpful to see what the conversion process generated. We then manually configured our application as described below. Problems Encountered XML Validation We tried multiple combinations for specifying the DTD's for the XML files: struts-config.xml and web.xml. Nothing seemed to work. The parser could not seem to resolve to the local copy of the DTD. We got around this by removing the DOCTYPE tag from the files and adding/setting the servlet parameter validating to false for the action servlet. ASCII vs EBCDIC It turns out that most files (jsp, xml, tld, resources, etc.) must be ASCII in order for WAS and Struts to process them. The only exception is the myapp.webapp file (described below). We use FTP to promote our files to the 390. Here's the confusing part... When you FTP in mode ASCII, an automatic conversion takes place, converting your text files to EBCDIC. To keep the files in ASCII format, you must FTP in mode BINARY. Key Files The key files for configuring WAS on OS/390 are detailed in the PIU document. I've noted some comments below and snippets/content for each that we touched in our installation. httpd.conf The configuration file for the Web server. A Service directive is needed to route requests through WAS for your application. # MYAPP application # Service /myapp/* /usr/lpp/WebSphere/uq56298/AppServer/bin/was350plugin.so:service_exit was.conf A properties file used to configure the application server and web applications. The key here is to only use the deployedwebapp items, do not include any webapp items. This way, WAS will look for the myapp.webapp file in your path for the webapp configuration. # # myapp application # deployedwebapp.myapp.host=default_host deployedwebapp.myapp.rooturi=/myapp deployedwebapp.myapp.classpath=/myapp/WEB-INF/classes:/myapp/WEB-INF/lib deployedwebapp.myapp.documentroot=/myapp deployedwebapp.myapp.autoreloadinterval=3 myapp.webapp An XML file that is similar to the web.xml standard for web application deployments. (The PIU document claims that it is the same, but it's