I've created a form similar to FaaS Example 2 (simple radio button form), and it seems to work great so far. My concern is with error handling.
I know that I can install client-side validation to ensure that all required fields are filled before the user can submit the form. But if the submission generates a server-side error (say, due to an incorrect credit card number), it seems thatonly the error comes back (via OnErrorUrl) – and the user has to re-enter all of the form fields. So I'm looking for a way to help the user by re-populating the field data they already entered.
Is there any way to accomplish this with FaaS? A way to post via AJAX, perhaps? Or a way for C&P to attach a long query string to the OnErrorUrl (that contains all the field info the user entered)?
Thanks!
I know that I can install client-side validation to ensure that all required fields are filled before the user can submit the form. But if the submission generates a server-side error (say, due to an incorrect credit card number), it seems thatonly the error comes back (via OnErrorUrl) – and the user has to re-enter all of the form fields. So I'm looking for a way to help the user by re-populating the field data they already entered.
Is there any way to accomplish this with FaaS? A way to post via AJAX, perhaps? Or a way for C&P to attach a long query string to the OnErrorUrl (that contains all the field info the user entered)?
Thanks!
Comment