Thanks for the explanation. We had worked out a similar solution where we compared get_field() with $value.
I’m having the same issue as @phylaxis where the validation works but sends me to a separate page instead of inline AJAX. Console indicates 500 internal server error even for the most basic validation.