You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am doing a POC with Umbraco Forms and I have a requirement to run some complex client side business rules when a user is moving between pages of a form.
So far, I have overridden the default themes Script.cshtml file and modified it to render a custom JS script which is working.
I am then attempting to run some custom validation when the form is submitted by hooking into the asp-net-validation library as documented here:
1.) If I use preventDefault() and the custom validation fails, my form buttons are disabled.
2.) If I return false without preventing the default event, the form submits anyway.
Can you provide any suggestions or code samples on how correctly hook into the validation pipeline?
Thanks,
Dean
This item has been added to our backlog AB#43271
The text was updated successfully, but these errors were encountered:
Hi,
I am doing a POC with Umbraco Forms and I have a requirement to run some complex client side business rules when a user is moving between pages of a form.
So far, I have overridden the default themes Script.cshtml file and modified it to render a custom JS script which is working.
I am then attempting to run some custom validation when the form is submitted by hooking into the asp-net-validation library as documented here:
https://github.com/haacked/aspnet-client-validation?tab=readme-ov-file#subscribing-to-client-form-validation-event
However, the "validation" event never fires.
I've also tried attaching a "submit" event like below but seem to run into issues:
1.) If I use preventDefault() and the custom validation fails, my form buttons are disabled.
2.) If I return false without preventing the default event, the form submits anyway.
Can you provide any suggestions or code samples on how correctly hook into the validation pipeline?
Thanks,
Dean
This item has been added to our backlog AB#43271
The text was updated successfully, but these errors were encountered: