I simply cannot get a json response in Safari, calling SoundCloud's API.
var inputSet={url:setUrl},
clientId={client_id:client_id};
$.getJSON( "https://api.soundcloud.com/resolve.json", $.extend(inputSet, clientId), function( data ) {
console.log(data);
});
This returns an Origin Access-Control error in Safari but not in Chrome. CORS is not working at all.
Saw CORS not working at all, implemented 'working' answer, exact same error, only Safari.
adding a callback parameter does not return that error, however returns the ajax error
"parsererror" SyntaxError {}
which I presume is due to the response still being json and not jsonp. This does not work in either browser.
As it stands I cannot get this cross domain request working in chrome, even though the docs
https://developers.soundcloud.com/docs#crossdomain
say I can.
Safari network tab:
Safari response:
[Error] Failed to load resource: Origin https://seam.li is not allowed by Access-Control-Allow-Origin. (17235000.json, line 0)
[Error] XMLHttpRequest cannot load https://api.soundcloud.com/playlists/17235000.json?client_id=CLIENT_ID. Origin https://seam.li is not allowed by Access-Control-Allow-Origin. (seam.li, line 0)
Linked page loads fine in browser.