I'm using this method:
protected boolean buttonPressed(
String name) {
if (req.getParameter(name) != null)
return true;
else
return false;
}
If the html is something like this:
<input type="submit" name="b_ok" value="Ok">
<input type="submit" name="b_cancel" value="Cancel">
you can
test for the button like this:
if(buttonPressed("b_ok"))
handleOk();
else
handleCancel();
This method also works when you have several languages for your web-site since you are testing against the name and not the value(label).
Stein