Form Validation

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to validate a field. The users can only enter the quantity in
multiple of 10. How do I do that?
 
KKXC said:
I am trying to validate a field. The users can only enter the
quantity in multiple of 10. How do I do that?

My guess
if (var % 10 == 0) alert('var is a multiple of 10')
else alert('var is not a multiple of 10')

If it works, change the alerts to code to ask the user to re-enter
 
Back
Top