Can you send the struts config file??? Regards Ayusman
-----Original Message----- From: Simons Kevin [mailto:[EMAIL PROTECTED] Sent: Thursday, September 08, 2005 1:00 AM To: Struts Users Mailing List Subject: class file mapping All, I am a newbie still testing things out to understand struts better. I have the following structure : java files in folder /classes. class files in folder /classes/test. This is al normal. I have create a simple index.jsp <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %> <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %> <html> <head> </head> <body> <html:form action="/index.do" focus="name"> <table> <tr> <td >Name:</td> <td><html:text property="name"/></td> </tr> </table> <html:submit>ok</html:submit> </html:form> </body> </html> The url is http://localhost:8080/tests/index.jsp. This loads perfect. When I hit the submit button he changes the url to http://localhost:8080/tests/index.do. Up till here I can follow. But then... Can someone explain me why I need to place my class files also in the classes folder. Otherwise he complains about a 500 error (didn't produce a class file). When I found that out, I get another 500 No action instance for path /index could be created. Apparently this means that my action file does not extend the action class but it does. package test; import org.apache.struts.action.Action; import org.apache.struts.action.ActionForward; import org.apache.struts.action.ActionMapping; import org.apache.struts.action.ActionForm; import org.apache.commons.beanutils.BeanUtils; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; public final class insertTestAction extends Action { public insertTestAction() {} public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception { testService service = new testService(); testForm testForm = (testForm) form; testDTO testDTO = new testDTO(); BeanUtils.copyProperties( testDTO, testForm ); service.insertTest( testDTO ); request.setAttribute("tests",testDTO); return (mapping.findForward("success")); } } Can someone tell me a bit more about those two things ( like why these happen, what I can do to avoid the errors). The weirdest thing in fact is the fact that I need to copy my class files into the classes too, normally he should look into the test folder... Greetz, -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.344 / Virus Database: 267.10.18/91 - Release Date: 6/09/2005 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] **************** CAUTION - Disclaimer ***************** This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely for the use of the addressee(s). If you are not the intended recipient, please notify the sender by e-mail and delete the original message. Further, you are not to copy, disclose, or distribute this e-mail or its contents to any other person and any such actions are unlawful. This e-mail may contain viruses. Infosys has taken every reasonable precaution to minimize this risk, but is not liable for any damage you may sustain as a result of any virus in this e-mail. You should carry out your own virus checks before opening the e-mail or attachment. Infosys reserves the right to monitor and review the content of all messages sent to or from this e-mail address. Messages sent to or from this e-mail address may be stored on the Infosys e-mail system. ***INFOSYS******** End of Disclaimer ********INFOSYS*** --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]