I\'m using Krajee the Bootstrap File Input plugin to perform an upload via AJAX call.
Here is the link to the Krajee plugin AJAX section: Krajee plugin AJAX
The
You can read the events section on the plugin documentation page to understand the various events provided by the plugin.
It depends on how you have setup the ajax upload in the plugin. The plugin offers two ajax upload modes - synchronous and asynchronous as described in the documentation. Its asynchronous if you have uploadAsync
property set to true
.
FOR AJAX SUCCESS TRAP:
FOR AJAX ERROR TRAP:
In your case you have set uploadAsync
set to true - so use the asynchronous settings/events.