Ajax request Canceld in Tizen’s emulator, but not in browser

I currently have an error with my tizen emulator when I try to contact a webservice through $.getJSON.

I have a button, when I click on it, I get the JSON from a webservice, simple as that. On my computer browser, this works perfectly, but when I run the code as an app on Tizen’s emulator (gear), the GET method returns : (canceled)
Request cancelled.

Here’s the code (main.js):

$(window).load(function(){document.addEventListener('tizenhwkey', function(e) {
    if(e.keyName == "back")
    getProductsOfUniverse(88);//Calls webservice
    return false;

function getProductsOfUniverse(universeId){
    //Works on desktop's Chrome
    $.getJSON( ""+universeId+"&customerId=", function( productJSON ) {
        var items = [];
          $.each( productJSON.product, function( key, val ) {
                    "<li> <div class="card_view">" +
                    "<div class="title"><strong>" + val.libelle + "</strong> </div>" +
                    "<div class="body">" + val.descriptionCourte + "</div>" +
                    "</div></li>" );
        .fail(function( err ) {
            //TODO Show error message
            console.log( err );

I can see the cancel error in Networks’s tab, but nothing shows up in Console.
I don’t know where the problem is in Tizen gear emulator, the code works perfectly in browser.


Source: ajax

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.