I wanted to know if there is a better way to layout my form without having to create four check-boxes for the user to input 4 quarters as 25+25+25+25 = 1.00 to buy a drink.
Currently, I just have one check-box for each denomination(Nickles, Dimes and Quarters) I want to use.
I was wondering if there is better way in php and html that I can set a button, so that the user can only click a button for just quarters such that one click equates to 25 on the php side, and two clicks equates to 50 on the php side.
For example a user can click the quarters button once, and the value sent to the php script should be 25, and if the user clicks on nickles twice the value should be 5+5 = 10.
<form>
<label>Input Money Denominations</label>
<br />
<LABEL><INPUT TYPE="checkbox" NAME="money1" VALUE="Quarters">Quarters</LABEL>
<LABEL><INPUT TYPE="checkbox" NAME="money2" VALUE="Dimes"> Dimes</LABEL>
<LABEL><INPUT TYPE="checkbox" NAME="money3" VALUE="Nickles"> Nickles</LABEL>
</form>
<!--They are distinguished by their unique VALUEs
Only the value of the checked checkboxes will be passed to the php script.-->
<!--End Checkboxes for money option-->
<!--Submit button-->
<INPUT TYPE="submit" NAME="money" VALUE="Submit Denomination">
<!--The type of button tells what it does. The name is optional unless you are using a script that requires it(php).