I don\'t really know how to title my question, but I have a JSP page with a table displaying elements from a database, and I want to have a button for each row to either del
I'm not sure why you have a table nested for just the buttons... perhaps it's for layout. I would suggest making each of your top-level have a form with another attribute identifying the row, and two submit buttons.
e.g. something like this (untested)
<s:form theme="simple">
<s:hidden key="rowID" />
<s:submit action="remove" value="Remove"/>
<s:submit action="edit" value="Edit"/>
</s:form>
You can have a single form with multiple actions for each. Just put something in the row that uniquely identifies the row that you'll be acting upon.
So, what'll happen is that when this is submitted, the rowID will be included in the request and sent to your specific action as a parameter to the setter (setRowID()). Just pick something from whatever your original data is that uniquely identifies it.