[CDS API] XmlHttpRequest from a not allowed IP
After my two first posts, i still have some questions, but i'm sure it will be useful for others too
I'm trying to make a JS XmlHttpRequest like this :
- Code:
function cds_info(token, object_id){
var xhr = new XMLHttpRequest();
xhr.open("GET", "http://my_server_ip:23424/cds/browse/flv_player/"+object_id+"/BrowseMetadata/all/0/1?authToken="+token);
xhr.setRequestHeader("Accept", "application/xml | application/json");
xhr.onreadystatechange = function () {
if (this.readyState == 4) {
alert('Object_id: '+object_id+'\nStatus: '+this.status+'\nHeaders: '+JSON.stringify(this.getAllResponseHeaders())+'\nBody: '+this.responseText);
}
};
xhr.send(null);
}
And i get this error message :
Origin http://my_server_ip is not allowed by Access-Control-Allow-Origin
How can i allow this request ?
Many thanks for your help !