The setup i got is: Apache Software Foundation\Tomcat 5.5\webapps\StrutsHello
and under StrutsHello
WEB-INF classes lib pages/ and under pages i got index.jsp inputname.jsp greeting.jsp
I got it working from index.jsp(which just has a logic redirect forward) to the inputname.jsp and when i press the submit button is seems to go to the greeting.do and does nothing.
try by removing .do in form action attribute html:form action="/greeting"
AnilPrakash Raju
Ranch Hand
Joined: Jul 26, 2004
Posts: 137
posted
0
Thanks Sai,
Tried your suggestion. It did not change anything. got the same issue.
Anil
sai prasanna
Ranch Hand
Joined: May 02, 2005
Posts: 167
posted
0
In the forward path attribute you try with pages/greeting.jsp or /pages/greeting.jsp
Sachin Kediyal
Greenhorn
Joined: May 11, 2006
Posts: 9
posted
0
Hi Anil, Replace your action mapping with this in struts-config.xml <action path="/greeting" type="sample.GreetingAction" name="GetNameForm" scope="request" input="/pages/inputname.jsp" > <forward name="sayHello" path="/pages/greeting.jsp"/> </action> The problem is the request is being passed to your GreetingAction Servlet.Your GreetingAction Servlet knows to dispatch the request to "sayHello" to generate the response but it is not able to locate greeting.jsp since you had not mentioned the complete virtual path of greeting.jsp correctly.You have mentioned only (/greeting.jsp). In the inputname.jsp your action tag should be like this <html:action name="/greeting">
AnilPrakash Raju
Ranch Hand
Joined: Jul 26, 2004
Posts: 137
posted
0
Thanks guys,
I stuffed in up in the Action
Made some changes to the Action but forgot to take the complied classes from eclipse to the tomcat directory.