I am using the getJSON command and using firebug for debugging, if I
go to this server i setup with this url: 
http://url/all_data.json?callback=getdata

It returns json data warped with getdata({data}). I have validated the
json part using jsonlint, so from firebug's net tab I get a param
(callback getdata), header and response, etc. as expected. But if I
use jquery's getjson, I get param, and header but the response is
empty and function callback doesn't trigger (no alert).

I have been pulling my hair out trying to solve this for the last few
hours (I know that getjson uses OPTIONS instead of GETS and I can see
that the request is made on the server and the json should be sent as
normal).

Here is my code for this section:

<script type="application/javascript">
function getdata(data){
        alert(data.name);
}
$.getJSON("http://130.216.208.254:10001/all_data.json?
callback=getdata");
</script>

Reply via email to