Form validation
The site backend has a number of forms for inserting and updating various database columns where the values can only be 0 or 1 and another can only be 1,2,3 or 4
These particular fields have a column type of tinyint(1)
I would like to apply validation to the field as it being entered, in the same way that the validation of the fields work in the registration page.
For example if you try to enter an email address in the email field which is not an email format and then move to the next field a mesage is instantly displayed and the field displays a red background.
Can this be done in the same way for a numeric field to check for an entry of only 0 or 1 and for only 1,2,3 or 4