Consider the following view in an HTML5 document:
<form method="post" action="http://example.com/submit/"> <button name="confirm" value="1" type="submit">Confirm</button> <button name="re-send" value="1" type="submit">Re-send code</button> <button name="cancel" value="1" type="submit">Cancel change</button> </form>
Using Chrome, clicking the first button creates the payload of the confirm=1 request. Similarly, the second button results in re-send=1 and three cancel=1 .
Examining the server side of the request payload allows me to determine which of the three buttons was pressed (provided that only one of the three keys is present in the request payload).
In all cases, the key: key pairs are not excluded from the request payload. It is very useful.
Is this behavior (that the key button is not pressed: value pairs are excluded from the request payload)?
source share