checking form validation code before refactoring (see msg)

the code in its current format needs a major refactor. two anonymous functions should probably be resuing code when they aren't. will come back to it sooner than later.