marxan
20 Jun 2012, 1:56 AM
Hello,
I'm trying to load data from a coldfusion server but I have the following issue:
"You're trying to decode an invalid JSON String"
When I have a look in firebug, I see that the call is correctly made to my component Loader.cfc but the method called is "getcfcinhtml" instead of "getFamilyCompo".
Here's the call to my component:
Ext.define('TAB.model.FamilyCompoModel', { extend: 'Ext.data.Model',
fields: ['codefc', 'namefc'],
proxy: {
type: 'ajax',
url: 'app/data/Loader.cfc?getFamilyCompo',
/* params:{
method: 'getFamilyCompo',
returnFormat: 'JSON'
},*/
success : function(response){
console.log(response.responseText); //<--- the server response
}
},
reader: {
type: 'json',
root: 'results'
}
}
});
Do I make anything wrong?
Thanks in advance
I'm trying to load data from a coldfusion server but I have the following issue:
"You're trying to decode an invalid JSON String"
When I have a look in firebug, I see that the call is correctly made to my component Loader.cfc but the method called is "getcfcinhtml" instead of "getFamilyCompo".
Here's the call to my component:
Ext.define('TAB.model.FamilyCompoModel', { extend: 'Ext.data.Model',
fields: ['codefc', 'namefc'],
proxy: {
type: 'ajax',
url: 'app/data/Loader.cfc?getFamilyCompo',
/* params:{
method: 'getFamilyCompo',
returnFormat: 'JSON'
},*/
success : function(response){
console.log(response.responseText); //<--- the server response
}
},
reader: {
type: 'json',
root: 'results'
}
}
});
Do I make anything wrong?
Thanks in advance