The behavior I'm trying to achieve (most efficiently) is having a form start out with the submit button enabled, but if there is a validation error, such as a required field being left blank on blur, the submit button is disabled. It's easy then to re-enable it when the user fills in that field, but harder to get the script to check and see if there are any other lingering errors before going ahead and enabling it.
My natural inclination would be to just keep a count of errors that increments and decrements when errors occur and are resolved. Then the script would check to see that the error count is 0 before re-enabling the submit button. It seemed easy, but I think I'm getting mixed up somewhere in conflicts of variable scope, and it's not turning out right.
A google search rendered an example where someone was using a string variable to store errors, concatenating and replacing data to the string as errors were logged/resolved. Any other methods out there as I try to implement a solution?