I have an html form for the user to enter details to buy a subscription with Paypal. I need to notify the user if those details are not entered adequately. I've found this https://developer.paypal.com/docs/checkout/integration-features/validation/#synchronous-validation which seems to give code to disable the Paypal buttons but that's not enough because the user needs to be told what information he hasn't entered correctly rather than just have the Paypal buttons disabled until he gets the information correct. Can I not keep the Paypal buttons enabled and notify the user if he clicks one of them when the form isn't completed fully and clicking the button then have no effect?
This must be a very standard thing to want to do. Rather than try to work it all out from scratch I thought I would ask here if anyone had any standard code for it that I could look at?