I am creating a product order form with JS and i was wondering if it is possible to hide a product/checkbox once the stock has finished ? I have the following HTML.
<input class="iput" type="checkbox" name="E33" value="33" stock="20"/> Product A
<input class="iput" type="checkbox" name="E34" value="33" stock="6"/> Product B
<input class="iput" type="checkbox" name="E66" value="33" stock="7"/> Product C
Lets say the 6 people have chosen product B while filling out the form, is possible to prevent the 7th user from being able to select product B as its stock will be finished by the time the 7th user arrives at the form ?
Aucun commentaire:
Enregistrer un commentaire