Hi, i hope this wasn't covered before, i used the search function and found nothing.
I am learning to work with struts, after i click on submit button (in a form) i get a blank page
struts-config.xml :
<struts-config>
<!-- Form Bean Definitions -->
<form-beans>
<form-bean name="eTrackingForm" type="eTrackingForm"/>
</form-beans>
<!-- Action Mapping Definitions -->
<action-mappings>
<action path="/setupeTrackingForm" forward="/eTrackingForm.jsp"/>
<action path="/inserteTracking"
type="inserteTrackingAction"
name="eTrackingForm"
scope="request"
validate="false"
input="/eTrackingForm.jsp"
>
<forward
name="success"
path="/confirmation.jsp"/>
</action>
</action-mappings>
<!-- message resources -->
<message-resources
parameter="ApplicationResources"
null="false" />
</struts-config>
Is something wrong there? if you need more files please tell me, i do not know what more to do, i check everything many times...
-
[Struts] Blank Page after submit (7 messages)
- Posted by: andres g
- Posted on: May 30 2004 16:52 EDT
Threaded Messages (7)
- I've seen this sadly enough. by Kris Thompson on May 30 2004 17:48 EDT
- spelling fine by andres g on May 30 2004 18:24 EDT
-
more files ? by J?rg Neumann on May 30 2004 08:49 EDT
-
Action by andres g on May 30 2004 10:33 EDT
-
Anyone ? by andres g on May 31 2004 06:33 EDT
- execute VS. Execute by Winston Campbell on June 01 2004 09:54 EDT
-
Anyone ? by andres g on May 31 2004 06:33 EDT
-
Action by andres g on May 30 2004 10:33 EDT
-
more files ? by J?rg Neumann on May 30 2004 08:49 EDT
- spelling fine by andres g on May 30 2004 18:24 EDT
-
I've seen this sadly enough.[ Go to top ]
- Posted by: Kris Thompson
- Posted on: May 30 2004 17:48 EDT
- in response to andres g
I've noticed that if you forward in your Action class to "nowhere" then it will truely take you to nowhere without throwing an error, so I would suggest double checking that the mapping you are trying to go to is "success" not succes" or something like that. -
spelling fine[ Go to top ]
- Posted by: andres g
- Posted on: May 30 2004 18:24 EDT
- in response to Kris Thompson
Thanks for the answer Kris, i re-checked what you said, and the spelling is fine. :(
Thanks -
more files ?[ Go to top ]
- Posted by: J?rg Neumann
- Posted on: May 30 2004 20:49 EDT
- in response to andres g
i just wonna be sure....
you did write an action at the declared source path that returned a forward to success, did you ? -
Action[ Go to top ]
- Posted by: andres g
- Posted on: May 30 2004 22:33 EDT
- in response to J?rg Neumann
inserteTrackingAction.java:
public final class inserteTrackingAction extends Action {
public ActionForward Execute(ActionMapping actionmapping, ActionForm actionform, HttpServletRequest httpservletrequest, HttpServletResponse httpservletresponse) throws Exception
{
eTrackingService etrackingservice = new eTrackingService();
eTrackingForm etrackingform = (eTrackingForm)actionform;
eTrackingDTO etrackingdto = new eTrackingDTO();
BeanUtils.copyProperties(etrackingdto,etrackingform);
etrackingservice.inserteTracking(etrackingdto);
httpservletrequest.setAttribute("eTracking",etrackingdto);
return actionmapping.findForward("success");
}
} -
Anyone ?[ Go to top ]
- Posted by: andres g
- Posted on: May 31 2004 18:33 EDT
- in response to andres g
Anyone ?
Thanks -
execute VS. Execute[ Go to top ]
- Posted by: Winston Campbell
- Posted on: June 01 2004 09:54 EDT
- in response to andres g
It looks like the signature of your execute method is Execute(...) with a capital "E". Could it be that your execute method is not being invoked because of this? -
thanks![ Go to top ]
- Posted by: andres g
- Posted on: June 01 2004 10:06 EDT
- in response to Winston Campbell
it was that!! i lost hours trying to figure it out!!!!
thanks!