function opening(event, nodes, node) {
alert("opening");
$.ajax({
url: 'https://permid.org/1-5000617737?format=json-ld',
type: "GET",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (data, textStatus, xhr) {
alert('success');
},
error: function (xhr,textStatus, errorThrown) {
alert("failed")
}
});
}
This function always returns failed alert.
I want to access permId data from my javascript/ajax code.