• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Form action attribute is set to root folder

 
Trivikram Kamat
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Root folder is struts.

web.xml:


struts-config.xml:


strutsForm.jsp


The above code sets form as:
<form name="sayHiForm" method="POST" action="/struts">
and not
<form name="sayHiForm" method="POST" action="StrutsSayHi.do">

Which field needs to be changed? Please help.
 
Trivikram Kamat
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oh, I totally forgot that I'd asked this question in this forum.

Line 19 from web.xml should be:


So that all files ending with .do extension can be forwarded to ActionServlet.
I wonder why it doesn't work with <url-pattern>/StrutsSayHi.do</url-pattern>
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic