HandleSubmitAction
Accepts a vote, and adds it to the correct poll and option.
Struts config
<action path="/poll/vote" type="com.escenic.poll.struts.HandleSubmitAction" name="submitForm" input="/poll/vote-input.jsp" validate="true"> <forward name="success" path="/poll/vote-success.jsp"/> <forward name="error" path="/poll/vote-error.jsp"/> </action>
Action Form
This action can be used with the following form:
com.escenic.poll.struts.SubmitForm
-
Gathers visitors' votes.
Action Forwards
The forwarding actions defined in this action.
success
-
Performed if the vote is successful. A vote can be successful even if the visitor has voted before. This forwarding action can be overridden from the HTML form by setting the 'redirectTo' property.
error
-
Performed if there is a configuration error.