|
|
How to install Struts 1.1b on WebSphere 3.5.4 (Missing ressources attribute org.apache.struts.action.MESSAGE)
By Renato Aganippe at Aug 1, 2002, 06:39 am UTC
------=_NextPart_000_07FB_01C237FB.D93826D0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi everybody! I'm triyng to put Struts 1.1b on WebSphere 3.5.4 but I have the = following message : Message : Server caught unhandled exception from servlet... More...
------=_NextPart_000_07FB_01C237FB.D93826D0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi everybody!
I'm triyng to put Struts 1.1b on WebSphere 3.5.4 but I have the = following message : Message : Server caught unhandled exception from servlet [Activateur de = service de fichiers]: Server caught unhandled exception from servlet = [Processeur JSP 1.1]: Missing resources attribute = org.apache.struts.action.MESSAGE
Does anybody have an idea? (I understand that the ressource file is not = availaible but where do I have to put it to make it available)
Then, is there someone who knows where I get an installation guide for = struts 1.1b on WebSphere 3.5.4?
Thanks a lot!
Renato Aganippe Cardiweb Web Developer
------=_NextPart_000_07FB_01C237FB.D93826D0--
11 Replies
|
|
|
Use session and request actionForm in same action
By xufang(CAP) at Aug 1, 2002, 03:50 am UTC
Hi! In my application i need two type of actionfrom to store user's information.every action class have it's actionForm(request scope) defined in mapping part of config file but also need access session scope actionForm created by login page. I serched the <MAILING LIST ARCHIVE> but can not find... More...
Hi! In my application i need two type of actionfrom to store user's information.every action class have it's actionForm(request scope) defined in mapping part of config file but also need access session scope actionForm created by login page.
I serched the <MAILING LIST ARCHIVE> but can not find the solution.
Thanks
Fang xu
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
Architecture advice....
By Michael Delamere at Aug 1, 2002, 01:42 am UTC
Hi, I had a discussion at work today concerning the best way to implement our application. A very basic discription of the framework would be the following: 1. Struts + Velocity for the view 2. Struts ActionServlets for the controller 3. Service layer/methods for querying persistence layer 4. OJB... More...
Hi,
I had a discussion at work today concerning the best way to implement our application. A very basic discription of the framework would be the following:
1. Struts + Velocity for the view 2. Struts ActionServlets for the controller 3. Service layer/methods for querying persistence layer 4. OJB persistence layer
The main debate was actually about what the service layer would look like. We thought about the following options:
1. The service layer consists of static methods 2. The service layer would consists of normal classes 3. The service layer could consist of servlets
The idea is that (this is nothing new of course) the service layer would purely have methods such as addToShoppingBasket() or checkLogin(); basically service methods which carry out the communication with the persistense layer and returns the result to the controller.
The question is though, should we create a new object every time we want to access a stateless method? Surely that would be a bit of an overhead. Go with servlets? This possibly ties it to the web-container too much and isn´t very elegant (?). Another option would be just to use static methods; can this cause a problem when wanting to distribute to more than one server? Is it better in terms of performance?
I would really appreciate some help and ideas on this. It would make things easier in terms of deciding on the next step.
Thanks in advance!
Regards,
Michael
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
28 Replies
|
|
|
Retrieve object from Vector
By Christian Pich at Aug 1, 2002, 01:06 am UTC
I have a bean - called ABean - that has a get method and retrieves a Vector where each Vector element has a new Object - say DetailBean. How do I get access to that bean in <bean:write name="question" property="weight" scope="request" filter="true"/> if that Vector were another bean I could just... More...
I have a bean - called ABean - that has a get method and retrieves a Vector where each Vector element has a new Object - say DetailBean. How do I get access to that bean in
<bean:write name="question" property="weight" scope="request" filter="true"/>
if that Vector were another bean I could just use the nested way to access those objects, such as property="weight.number.total" which is short for ABean.getWeight().getNumber().getTotal(). Now how do I handle a Vector and retrieve its elements? (Vector does not have a get method).
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
1 Reply
|
|
|
Upload failure in MultipartValueStream
By frankie cevallos at Aug 1, 2002, 12:19 am UTC
Hi all, I just implemented file upload using Struts and am experiencing odd behavior concerning plain text file uploads close 700Kb and above. My development environment includes VAJ4, Struts 1.0, and am testing in VAJ's WTE. The file upload works well for files less than 700Kb but throws the... More...
Hi all,
I just implemented file upload using Struts and am experiencing odd behavior concerning plain text file uploads close 700Kb and above. My development environment includes VAJ4, Struts 1.0, and am testing in VAJ's WTE. The file upload works well for files less than 700Kb but throws the following for anything larger:
java.io.IOException: end of stream before boundary found! java.lang.Throwable(java.lang.String) java.lang.Exception(java.lang.String) java.io.IOException(java.lang.String) org.apache.struts.upload.MultipartValueStream(java.io.InputStream, java.lang.String) java.io.File org.apache.struts.upload.MultipartIterator.createLocalFile() org.apache.struts.upload.MultipartElement org.apache.struts.upload.MultipartIterator.getNextElement() void org.apache.struts.upload.DiskMultipartRequestHandler.handleRequest(javax.servlet.http.HttpServletRequest) ==== snipped === ---------------------------------------- My ActionForm:
package org.frb.ny.idd.gui.forms; public class BeneFileActionForm extends ActionForm { protected FormFile beneFile; protected String loadBenefilename;public org.apache.struts.upload.FormFile getBeneFile() { return beneFile; } public java.lang.String getLoadBenefilename() { return loadBenefilename; } public void setBeneFile(org.apache.struts.upload.FormFile newBeneFile) { beneFile = newBeneFile; } public void setLoadBenefilename(java.lang.String newLoadBenefilename) { loadBenefilename = newLoadBenefilename; } } ---------------------------------------- My jsp: <%@ page language="java" %> <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %> <SCRIPT language="JavaScript" src="/JavaScripts/util.js"></SCRIPT> <SCRIPT language="JavaScript" src="/JavaScripts/LoadFile.js"></SCRIPT>
<html:form action="loadBene" enctype="multipart/form-data" onsubmit="return confirmLoad()" >
<html:hidden property="loadBenefilename" value="none"/> Please enter the file to be loaded <BR> <html:file property="beneFile" /> <html:submit value="Load"/> <html:button value="Cancel" property="cancel" onclick="window.close();"/>
</html:form> ----------------------------------------
Does anyone know what could be causing this error? Besides some javascript, there's not too much difference between this implementation and the Struts example.
Thanks so much in advance, Frankie
=====
___________________ frankie cevallos h) 212/316.2039 c) 646/773.7299
__________________________________________________ Do You Yahoo!? Yahoo! Health - Feel better, live better http://health.yahoo.com
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
1 Reply
|
|
|
LogConfigurationException when compiling JSP
By Nelson, Tracy (ETW) at Aug 1, 2002, 12:10 am UTC
I'm trying to write my first Struts app. I am using the struts-blank application included with the 1.1b1 distribution. I have my classpath and libraries all set up, and I think I have my struts-config.xml file set up correctly. When I attempt to compile any of my jsp files, however, my IDE have a... More...
I'm trying to write my first Struts app. I am using the struts-blank application included with the 1.1b1 distribution. I have my classpath and libraries all set up, and I think I have my struts-config.xml file set up correctly. When I attempt to compile any of my jsp files, however, my IDE (Oracle JDeveloper) tells me I have an HTML error (missing <HTML> tag [I do have a <html:html> tag]) and the compiler gives me an ExceptionInInitializerError: LogConfigurationException. I'm guessing this is due to a missing default LogFactory implementation, but I can't see why that would be. The commons-logging.jar file is on my classpath. Is there something else I need to set? I checked the javadoc for the logging facility, and it seemed to indicate that if no log factory was configured, a default would be used, is that right?
I have also installed the example application that came with the 1.1b1 distribution, and it works just fine. Is it possible I've gotten something mixed up in my struts-config.xml file that could be causing this?
Cheers! -- Tracy Nelson
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
reload the current page?
By Struts Newsgroup (@Basebeans.com) at Aug 1, 2002, 12:10 am UTC
Subject: reload the current page? From: "David Chu" <davidchu@aol.net> Given that I am in an arbitrary page in my webapp, I have a header at the top of each page that is a toggle button for some user state. If the user clicks the button, I want to reload the current page, with the user state... More...
Subject: reload the current page? From: "David Chu" <davidchu@aol.net> === Given that I am in an arbitrary page in my webapp, I have a header at the top of each page that is a toggle button for some user state. If the user clicks the button, I want to reload the current page, with the user state changed. This is tricky because the request.getHeader("referer") is sometimes not the most recent path of the Action just performed (in the case of Actions forwarding to other Actions).
I think one way to accomplish this is write the current requested Action's path to a session variable, for example, "/ViewShoppingCart.do," and, if the next action is the click of the toggle button, forward to this path again after doing what I need to (i.e. changing user state).
The problem is I do not know how to find a reference to any given Action's path which are defined in the struts-config.xml. How could I access this, or how else could I accomplish this?
Thanks for the help!
-- -david
------------------------------ David C. Chu America Online Network Tools Intern ------------------------------
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
RE: ActionErrors in ActionForm and JSP not showing up...
By Keith (corp-staff) USX Kamholz at Jul 31, 2002, 10:57 pm UTC
You don't need the <logic:messagesPresent>. It automatically checks to see if errors are present, so you can just use the font tag and the <html:errors/>. If there are no errors, it won't write anything out. I don't know if this would solve your issue, but maybe it has something to do with it. ~... More...
You don't need the <logic:messagesPresent>. It automatically checks to see if errors are present, so you can just use the font tag and the <html:errors/>. If there are no errors, it won't write anything out. I don't know if this would solve your issue, but maybe it has something to do with it.
~ Keith http://www.buffalo.edu/~kkamholz
-----Original Message----- From: [email protected: wbc...@Ensign-BickfordInd.com] [email protected: wbc...@Ensign-BickfordInd.com] Sent: Tuesday, July 30, 2002 10:21 AM To: [email protected: struts...@jakarta.apache.org] Subject: ActionErrors in ActionForm and JSP not showing up...
if (this.companySelection == null || this.companySelection.equals("")) { System.out.println("FormPremadeReport:validate > No Company Selected"); errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.requestform.company.required")); } return errors;
I have the above code in my ActionFormValidate... When I submit the form it passes the IF (as it should) and returns me to the HTML form page. BUT my JSP for:
<logic:messagesPresent> <!-- Errors detected --> <font color="Red"><html:errors/></font> </logic:messagesPresent>
Sends back the comment and font tags, but nothing after that...
Any ideas? I do have the application properties for all the settings, plus the shown resource above...
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
18 Replies
|
|
|
Reset button does not invoke the FormBean's reset()
By Priyank x57787 Gupta at Jul 31, 2002, 10:04 pm UTC
------_=_NextPart_001_01C238D1.7D9D0D00 Content-Type: text/plain; charset="iso-8859-1" Hi All, I am not able to invoke FromBean's reset() method from the browser. I have a form with two buttons Submit and Reset. When I click the reset button I am not able to invoke the reset() of the FormBean. Any... More...
------_=_NextPart_001_01C238D1.7D9D0D00 Content-Type: text/plain; charset="iso-8859-1"
Hi All, I am not able to invoke FromBean's reset() method from the browser. I have a form with two buttons Submit and Reset. When I click the reset button I am not able to invoke the reset() of the FormBean. Any help will be great. Thanks Priyank
------_=_NextPart_001_01C238D1.7D9D0D00--
6 Replies
|
|
|
How to connect a COM environment to struts ?
By Martin Kuypers at Jul 31, 2002, 9:06 pm UTC
Does anyone have an example how a visual basic program can connect to a struts environment, because i have all the Bussines Logic in a Struts MVC model and would not like to change it So if anyone has an example about a visual basic program connecting to this world, then this would mean a big Help... More...
Does anyone have an example how a visual basic program can connect to a struts environment, because i have all the Bussines Logic in a Struts MVC model and would not like to change it So if anyone has an example about a visual basic program connecting to this world, then this would mean a big Help for me
Thanks
Martin
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
6 Replies
|
|
|
Invoking controllers from code
By Will Spies/Towers Perrin at Jul 31, 2002, 8:47 pm UTC
Does anyone know the best way to invoke a struts controller from within a struts controller? This URL points to a JUnit struts-test-case --> http://strutstestcase.sourceforge.net/ so I know it's possible ( I just don't want to use this test case JAR ). Thanks for any help, More...
Does anyone know the best way to invoke a struts controller from within a struts controller?
This URL points to a JUnit struts-test-case --> http://strutstestcase.sourceforge.net/ so I know it's possible ( I just don't want to use this test case JAR ).
Thanks for any help,
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
How to get a handle to ActionMappings from within an Action
By George Cutrell at Jul 31, 2002, 8:37 pm UTC
------_=_NextPart_001_01C238C3.4B2EC650 Content-Type: text/plain; charset="ISO-8859-1" How do you get a hold of the ActionMappings from within an Action? I have the case where I need to forward to another action but before doing so I need to setup the form bean for that action. To properly set the... More...
------_=_NextPart_001_01C238C3.4B2EC650 Content-Type: text/plain; charset="ISO-8859-1"
How do you get a hold of the ActionMappings from within an Action? I have the case where I need to forward to another action but before doing so I need to setup the form bean for that action. To properly set the form bean in either the request or session, I need to get its attribute name. mapping.getAttribute() returns the attribute name of the form bean within the context of the present action. How do I do the same but for another action and form? Thanks, George Cutrell Technical Manager, Wireless Applications Development Nextel Communications, Inc. Desk: 703.433.8868 Mobile: 703.926.7851
------_=_NextPart_001_01C238C3.4B2EC650--
1 Reply
|
|
|
Visual GUI Designer for Struts
By Steve Eynon at Jul 31, 2002, 8:26 pm UTC
Hello, I've written a visual GUI designer for Struts using Microsoft Visio. It can be found at: http://www.alien-factory.co.uk/struts/struts-index.html I believe it works in a similar vein to Scioworks Camino in that you drag'n'drop Web Pages, Form Beans and Actions, link them up, add a couple of... More...
Hello,
I've written a visual GUI designer for Struts using Microsoft Visio. It can be found at:
http://www.alien-factory.co.uk/struts/struts-index.html
I believe it works in a similar vein to Scioworks Camino in that you drag'n'drop Web Pages, Form Beans and Actions, link them up, add a couple of properties, click a button and out pops your "struts-config.xml" file.
I originally wrote it for myself for I believe it is a lot easier to build robust web applications (without broken links, etc) visually rather than pouring over pages and pages of XML.
It is only in its first release but I thought others may find it useful too. If it is of genuine interest to anyone then how would I go about establishing a link to it from the Struts Resources page?
Thanks for reading so far and all (any?) comments are welcome.
Kind regards,
Steve.
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
3 Replies
|
|
|
Internationalizing large amounts of text
By Steven Banks at Jul 31, 2002, 7:56 pm UTC
I have been asked to convert some static html pages to jsp pages using = Struts. These pages include several very large paragraphs, like important = notices and privacy statements. Should all this text be put into the applicationResource.properties file? = Is it acceptable to have the appropriately... More...
I have been asked to convert some static html pages to jsp pages using Struts. These pages include several very large paragraphs, like important notices and privacy statements.
Should all this text be put into the applicationResource.properties file? Is it acceptable to have the appropriately internationalized static html text included in the page using an equals tag to determine which language version to include.
Steven Banks 368-0566
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
3 Replies
|
|
|
2 Jsp's and 1 form bean using tiles !!!! URGENT HELP
By Samip Ladhawala at Jul 31, 2002, 7:04 pm UTC
Hi Guys, I am using struts and tiles in my project. Here is my problem. I need to put 2 JSP's in the body of one definition of tiles. My definition looks like below: <definition name="fda.limitsEnter.body" path="/layouts/columnsLayout.jsp"> <put name="numCols" value="1" /> <putList name="list0" >... More...
Hi Guys,
I am using struts and tiles in my project. Here is my problem. I need to put 2 JSP's in the body of one definition of tiles. My definition looks like below:
<definition name="fda.limitsEnter.body" path="/layouts/columnsLayout.jsp"> <put name="numCols" value="1" /> <putList name="list0" > <add value="/accountCodeList.jsp"/> <add value="/limitsAdd.jsp"/> </putList> </definition>
I am using same form bean for both the JSP's. Now the problem is whenever I submit the form from the second JSP i.e. "limitsAdd.jsp in above definition", form bean is not getting populated. How can we resolve this problem? Does tiles support this functionality?
Any help will be appreciated.
Thanks Samip.
__________________________________________________ Do You Yahoo!? Yahoo! Health - Feel better, live better http://health.yahoo.com
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
AAARRRGGGGG -> ActionErrors in ActionForm and JSP not showing up...
By wbc...@ensign-bickfordind.com at Jul 31, 2002, 7:03 pm UTC
Any one have any other ideas? I cannot figure this one out! More...
Any one have any other ideas? I cannot figure this one out!
-----Original Message----- From: Chmura, William B. Sent: Wednesday, July 31, 2002 9:35 AM To: struts-user Subject: RE: ActionErrors in ActionForm and JSP not showing up...
Yes, the page that displays them is the same one that the errant information is missing from. Yes, I am also using Tiles on all these pages...
The <logic:messagesPresent> tag works fine and activates when an error should be appearing, but the <html:errors> tag seems awry. Or I am. Or
both of us...
Any help would be greatly appreciated ...
This is my form-beans and action from the struts-config.xml
<form-beans> <form-bean name="FormPremadeReport" type="com.ebind.twizard.reports.struts.FormPremadeReport" /> </form-beans>
<action path="/premadeReport" type="com.ebind.twizard.reports.struts.ActionPremadeReport" parameter="reportType" name="FormPremadeReport" scope="request" validate="true" input="twizard.premade"> <forward name="continue" path="twizard.premade" redirect="false" /> <forward name="displayRedReport" path="twizard.reportdisplay.ranged" redirect="false" /> <forward name="displayYellowReport" path="twizard.reportdisplay.ranged" redirect="false" /> <forward name="displayGreenReport" path="twizard.reportdisplay.ranged" redirect="false" /> <forward name="success" path="twizard.reportdisplay.ranged" redirect="false" /> </action>
<logic:messagesPresent> <!-- Errors detected --> <font color="Red"> Reported Errors:<br> <html:errors property="company"/> </font> </logic:messagesPresent>
<html:form action="/premadeReport.do" name="FormPremadeReport" type="com.ebind.twizard.reports.struts.FormPremadeReport" scope="request">
-----Original Message----- From: martin.cooper [email protected: martin.c...@tumbleweed.com] Sent: Tuesday, July 30, 2002 9:22 PM To: struts-user Subject: RE: ActionErrors in ActionForm and JSP not showing up...
Is the page that's supposed to display the errors returned from the same request that found them? This may not be the case if you are using frames, redirect or Tiles. The errors are saved as a request attribute, so if it's not the same request, the errors will be gone.
-- Martin Cooper
> -----Original Message----- > From: [email protected: wbc...@Ensign-BickfordInd.com] > [email protected: wbc...@Ensign-BickfordInd.com] > Sent: Tuesday, July 30, 2002 7:21 AM > To: [email protected: struts...@jakarta.apache.org] > Subject: ActionErrors in ActionForm and JSP not showing up... > > > > > if (this.companySelection == null || > this.companySelection.equals("")) { > System.out.println("FormPremadeReport:validate > > No Company > Selected"); > errors.add(ActionErrors.GLOBAL_ERROR, new > ActionError("error.requestform.company.required")); > } > return errors; > > > I have the above code in my ActionFormValidate... When I submit the > form it passes the IF (as it should) and returns me to the HTML form > page. BUT my JSP for: > > <logic:messagesPresent> > <!-- Errors detected --> > <font color="Red"><html:errors/></font> > </logic:messagesPresent> > > Sends back the comment and font tags, but nothing after that... > > Any ideas? I do have the application properties for all the > settings, > plus the shown resource above... > > > > > > > > -- > To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
0 Replies
|
|
|
Action from a Link
By Ryan Cuprak at Jul 31, 2002, 6:59 pm UTC
Hello, Is it possible to kickoff an action from a 'link'. For instance I created a 'Logoff' Action (extends Action) which removes session information and forwards the user back to the login page. In the initial hacked together prototype I have a logout link (not part of a form) on a page. Is it... More...
Hello, Is it possible to kickoff an action from a 'link'. For instance I created a 'Logoff' Action (extends Action) which removes session information and forwards the user back to the login page. In the initial hacked together prototype I have a logout link (not part of a form) on a page. Is it possible to have the link execute the LogoffAction or is the better solution to write a servlet that the performs this logic? I know I could embed logic in the login jsp page that invalidates the session if it exists (which I will probably add) but I am curious as to whether it is possible to run an action from a link.
Thanks, Ryan
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
2 Replies
|
|
|
Struts directory structure
By Heligon Sandra at Jul 31, 2002, 6:19 pm UTC
I am trying to organize the Struts files structure for my application. The files structure will be placed in the $CATALINA_HOME\webapps\MyWebApp\WEB-INF\src directory. Has someone any comment or advice about the following structure: <src - <MyDomain - <MyWebApp - <Controller MyRequestProcessor.java... More...
I am trying to organize the Struts files structure for my application. The files structure will be placed in the $CATALINA_HOME\webapps\MyWebApp\WEB-INF\src directory.
Has someone any comment or advice about the following structure:
<src - <MyDomain - <MyWebApp - <Controller MyRequestProcessor.java MyListener.java <Action
- <View <ActionForm
- <Model JavaBean sources
- <Common The Model directory has only to contain Java sources linked to the web application. The JavaBean classes shared between multiple applications (web or simple Java application) must be placed in an other directory common perhaps ?
If someone has other structure proposition, I am very interested. Thanks a lot in advance.
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
3 Replies
|
|
|
Problem validating dynamic Form with Validator-Framework
By Axel Stahlhut at Jul 31, 2002, 6:18 pm UTC
------=_NextPart_000_0019_01C238C3.426AF840 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, I've gfot problems with the validation Framework. (Struts 1.1b) If i try to validate a DynaValidatorForm I get the following error:... More...
------=_NextPart_000_0019_01C238C3.426AF840 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi, I've gfot problems with the validation Framework. (Struts 1.1b) If i try to validate a DynaValidatorForm I get the following error: java.lang.NullPointerException at = org.apache.struts.action.DynaActionForm.getDynaProperty(DynaActionForm.ja= va:539) at org.apache.struts.action.DynaActionForm.set(DynaActionForm.java:357) at = org.apache.struts.action.DynaActionForm.reset(DynaActionForm.java:158) at = org.apache.struts.validator.DynaValidatorForm.reset(DynaValidatorForm.jav= a:357) at = org.apache.struts.util.RequestUtils.createActionForm(RequestUtils.java:61= 8) at = org.apache.struts.action.RequestProcessor.processActionForm(RequestProces= sor.java:349) at de.neusta.j2ee.struts.NeustaRequestProcessor.process(Unknown Source) at = org.apache.struts.action.ActionServlet.process(ActionServlet.java:1109) at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:452) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at = org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applicat= ionFilterChain.java:247) at = org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilte= rChain.java:193) at = org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve= .java:243) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:566) at = org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:47= 2) at = org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at = org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve= .java:190) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:566) at = org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.jav= a:246) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:564) at = org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:47= 2) at = org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at = org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343= ) at = org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:= 180) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:566) at = org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherVal= ve.java:170) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:564) at = org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:= 170) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:564) at = org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)=
at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:564) at = org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:47= 2) at = org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at = org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.j= ava:174) at = org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.jav= a:566) at = org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:47= 2) at = org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943) at = org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.ja= va:1012) at = org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1= 107) at java.lang.Thread.run(Thread.java:484)
My struts-config (extracts): <form-bean name=3D"createStandortForm" = type=3D"org.apache.struts.validator.DynaValidatorActionForm"><form-proper= ty name=3D"name" type=3D"java.lang.String" initial=3D"" /><form-property = name=3D"street" type=3D"java.lang.String" initial=3D"" /><form-property = name=3D"city" type=3D"java.lang.String" initial=3D"" /><form-property = name=3D"zipCode" type=3D"java.lang.String" initial=3D"" /><form-property = name=3D"description" type=3D"java.lang.String" initial=3D"" = /><form-property name=3D"phone" type=3D"java.lang.String" initial=3D"" = /><form-property name=3D"fax" type=3D"java.lang.String" initial=3D"" = /><form-property name=3D"mobile" type=3D"java.lang.String" initial=3D"" = /><form-property name=3D"locType" type=3D"java.lang.String" initial=3D"" = /></form-bean></form-beans> <action path=3D"/StandortErzeugen" name=3D"createStandortForm" = scope=3D"session" validate=3D"true" input=3D"/StandortErzeugen" = type=3D"de.neusta.fortuna.webapp.standort.CreateStandortAction"> = <forward name=3D"success" path=3D"/Standort/StandortErzeugen.jsp" /> = <forward name=3D"created" path=3D"/StandortVerwaltung.do" /> = </action> <plug-in className=3D"org.apache.struts.validator.ValidatorPlugIn"> = <set-property = property=3D"pathname"value=3D"/WEB-INF/validator-rules.xml"/> = <set-property property=3D"pathname" value=3D"/WEB-INF/validator.xml"/> = </plug-in></struts-config>
Validator-rules.xml:
<validation-rules><validator name=3D"required" = classname=3D"org.apache.struts.validator.util.StrutsValidator" = method=3D"validateRequired" methodParams=3D"java.lang.Object, = org.apache.commons.validator.ValidatorAction, = org.apache.commons.validator.Field, = org.apache.struts.action.ActionErrors, = javax.servlet.http.HttpServletRequest" msg=3D"errors.required"> = </validator> <validator name=3D"mask" = classname=3D"org.apache.struts.validator.util.StrutsValidatorUtil" = method=3D"validateMask" depends=3D"required" = msg=3D"errors.invalid"> </validator></validation-rules> validator.xml: <form-validation><formset><form = name=3D"createStandortForm"><fieldproperty=3D"name"depends=3D"required"><= arg0 key=3D"error.required"/></field></form></formset></form-validation> Please help... Getting crazy on that since two days.
Axel
------=_NextPart_000_0019_01C238C3.426AF840--
3 Replies
|
|
|
html:link
By René Eigenheer at Jul 31, 2002, 4:39 pm UTC
I guess this question was asked several times ago, but I don't find the solution - sorry to ask again: I have an URL stored within a database and would like to generate <a href="xyz">. Therefore I try to use <html:link> but this tag does not accept form bean properties. As a work around I used an... More...
I guess this question was asked several times ago, but I don't find the solution - sorry to ask again:
I have an URL stored within a database and would like to generate <a href="xyz">.
Therefore I try to use <html:link> but this tag does not accept form bean properties. As a work around I used an idea I've read in another post using <bean:define> to store the url value in a variable and use this one with <%= variable %>.
Does anybod know where there is a more struts like solution using the value out of the form bean?
TIA Rene
-- To unsubscribe, e-mail: <mailto:struts-user-unsubscribe@jakarta.apache.org> For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>
3 Replies
|
|
 | |