added key up feedback for form validation and modularized validation functions