I have a url contain all the json format.
function load() { dashcode.setupParts(); var link = 'http://api.musixmatch.com/ws/1.1/track.search?apikey=d34fb59a16877bd1c540aa472491825b&q_track=back%20to%20december&page_size=10'; req.open = ("GET", link, false); req.onreadystatechange = readXML(); req.send(null); } function readXML(){ alert(req.responseText); } this code keep saying null all the time. Are there any way that i can retrieved those json text
readXMLdirectly and assign its return value toonreadystatechangeinstead of the function itself. Also note that you cannot simply make requests to 3rd party domains. You'd have to make use of JSONP, which the server has to support.