Page 1 of 1
nuAjax error
Posted: Wed Mar 02, 2016 8:29 pm
by nekpap
Hi,
is there any way to get a notification when nuAjax fails due to an error (for example a connection error)?
Thanks
Nektarios
Re: nuAjax error
Posted: Thu Mar 17, 2016 5:07 am
by david
nekpap,
If you are using the latest version of nuBuilder, you can pass a fail function to nuAjax();
Example:
Code: Select all
nuAjax(
'PROCEDURE_CODE',
{
async:true,
data:{
data_to_send_to_procedure: 'test'
},
done: function(){
alert('Done.');
},
fail: function(){
alert('Failed, connection error.');
},
always: function(){
alert('Finished ajax call.');
}
}
);
Re: nuAjax error
Posted: Sun Apr 03, 2016 6:10 pm
by nekpap
Thanks David! I will try it!
Re: nuAjax error
Posted: Thu May 19, 2016 3:05 am
by admin
.