You need to map the "names" of the actions to the actual Action classes you created. If you follow the example and have the struts.xml file like:
<action name="mySubmitAction" class="MySubmitAction">
<result>submit.jsp</result>
</action>
<action name="myClearAction" class="MyClearAction">
<result>submit.jsp</result>
</action>
When you click on the input generated by <s:submit value="Submit"/>
Struts2 will execute your execute
method in your MySubmitAction
. When you click on the input generated by <s:submit value="Clear" action="myClearAction"/>
struts2 is supposed to override the default action specified by the s:form
tag (I haven't tested it) and will execute the execute
method in your MyClearAction
.