Reputation: 4361
I create a form with Struts 2, using the following code :
<s:form id="form" onSubmit="getParameters();">
I don't understand why the generated is the following one :
<form id="form" name="form" action="/Projet/ListAction.action" method="post" onSubmit="return getParameters();">
Here is my struts.xml
<action name="ListBrochures" class="fr.web.actions.ListAction" method="execute">
<result name="success">listAction.jsp</result>
</action>
Why i have an action called ListAction.action. My aim is not to submit the form but to send a Ajax request. So as this action is called before my Ajax call, this bring trouble in my project. I just want that Struts does not generate the action in my form. I did not specify any action. Thanks for helping.
Upvotes: 1
Views: 1714