Every developers who coding with javascript will get sooner or later “Origin null” error, when they tried loading json/xml data from their local computer (working in firefox), or from external server. That is not allowed with new modern browsers for better security. You can watch your http request header and see “Origin: null” because browser block automatically these cross-domain request.

You have some issues to solve this problem:

1. If target server service JSONP use it. You only have to add param callback=? end of url. “getJSON()” jQuery request add callback parameter automatically.

2. Install some http-server, and run your javascript code from there. Ex. Linux: Apache2, Windows: Mongoose (only for developing).

3. Not recommend but could issue which working is try to some older browsers versions where origin policy is not so tight.

4. This issues still working on firefox:
Do your cross-domain json request in browser and copy-paste response for file ex. “name.json” and save. Now you can locally get this files working (in jQuery: $.getJSON(‘name.json’)).

Hox for PhoneGap developers!
If you made apps with PhoneGap, you can easily develop your app with one trick. Let see this guide: http://docs.phonegap.com/en/2.2.0/guide_whitelist_index.md.html#Domain%20Whitelist%20Guide