I have experienced this in the last two days. I guess JQMobi (Intel AppFramework) is a lightweight version of JQuery plus a customizable user interface platform for mobile devices (iOS and Android). Read a lot about jQuery Deferred () methods on many websites and blogs and have tried to implement some examples in my phonegap project that uses JQMobi. My ajax calls are executing correctly and a successful callback is successful:
$.ajax({ url: 'http://drsolution.com.br/teste/texts.json', async: true, dataType:'json', success: function(data) {
But when I try to use the deferred callback methods in the promise object returned by the ajax call, I get no response from them:
$.ajax({ url: 'http://drsolution.com.br/teste/texts.json', async: true, dataType:'json', success: function(data) { // do something with the json object, THIS IS ALWAYS WORKING }, error: function(error) { console.log("error"); } }).done(function{ // never fired }).fail(function { // never fired }).always(function { //never fired });
What's happening? Deferred object not implemented in JQMobi (Intel AppFramework)?
Thanks in advance.
source share