I am new to the web and I need to get a JSON object for a webpage that displays data:
{ "expires": "2011-09-24T01:00:00", "currencies": { "BZD": { "a": "2.02200", "b": "1.94826" }, "YER": { "a": "220.050", "b": "212.950" } }
I tried using jquery $ .getJSON to get the object, but it did not work.
<script> $.getJSON("http://m.somewebsite.com/data", { format: "json" }, function(data) { document.getElementById('test').innerHTML = data; }); </script>
I am wondering how to get this information correctly?
source share