Threaded View

  1. #1
    Sencha User
    Join Date
    Dec 2013
    Posts
    84
    Answers
    6
    Vote Rating
    48
    Malte123 is infamous around these parts Malte123 is infamous around these parts

      0  

    Default Answered: Ext.Ajax.request response.status 0 but file is loaded

    Answered: Ext.Ajax.request response.status 0 but file is loaded


    Hey all :-)

    I try to load a file within base64 in ...

    PHP Code:
    Ext.Ajax.request({
                
    urlthis.configFileName,
                
    method'GET',
            
    //    binary: true,  // makes it more worse: no responseText in Output
                
    success: function(response) {
                    var 
    cfg Ext.decode(response.responseText);
                    
    loadSuccessHandler(cfg); // callback function given as param functioncall
                
    },
                
    failure: function(response) {
                  
    loadErrorHandler("Could not get "+this.configFileName+" - server response was " response.status); // this is 0
                  
    console.log(response); // 
                
    }
            }); 
    Output on console:
    XHR finished loading: "file:///Users/noman/Documents/workspace/fassade/tests/app/config/config.cfg?_dc=1388973757477".
    Could not get undefined - server response was 0
    |> Object
    In my opinion I shouldn't see content in responseText like this (if failure sayes status=0):
    HTML Code:
    responseText: WW91IGFyZSBhIHNub29weSBFeHRKUyBIZXJvIDotKQ0KUGxlYXNlIGhlbHAgbWUgdG8gZmluZCBhIHNvbHV0aW9uICENCkkgdm90ZSB5b3UgdXAgYW5kIHNlbGVjdCB0aGUgYmVzdCBhbnN3ZXIgb2YgY2F1c2UgIQ0KSWYgeW91IHZvdGUgbWUgYWxzbyB1cCBJIHdpbGwgcG9zdCBteSBzb2x1dGlvbiBpZiB0aGVyZSBpcyBubyBzb2x1dGlvbiBwb3N0ZWQgYnkgb3RoZXJzLg==
    If I activate the flag binary: true I will loose my responseText in Object (console.log .. see above)

    For this: Everything does the opposite thinks than I expected !!!

  2. This will only happen loading files directly off the filesystem. If you put this through a server it'll work fine.

    See the code for the parseStatus method of Ext.data.Connection. A code of 0 is treated as an error. This is not straightforward as 0 could mean success or failure and applies when a real status code is not available.

    If you really must work directly off the filesystem then you can override the relevant parts of Connection easily enough.

Thread Participants: 2

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi