Catch form-ajax-submit-onchange programmatically

Hi,

I like the built in catch form-ajax-submit-onchange function. But I do have a case now where I can not just call a URL on submit. It is a JSON API and I need to process the request internally. Is there an easy way to just catch the built in form/submit/onchange event instead of calling the url given in the form action attribute?

1 Like

Hi! Try this:
in HTML:

<input  action="javascript:void(0)" onchange="SomeFunction()">

in app.js

function SomeFunction () {
  ///... submit event code...  
}

Hi… yes - this should do the job. The built in function does all this already very handy and I was just wondering if there is a way to use it instead of catching all changes again for this purpose by simply redirect the default ajax request to a function instead… somehow.

I have the same wish.