I am making a request to a cross-domain server for data to populate a Syncfusion Grid. The error I am getting is along the lines of:xmlhttprequest cannot load no 'access-control-allow-origin'.... The response had HTTP status code 405. This error is caused by a request that crosses two different domains. I Google the problem and see that the ej.DataManager request needs to employ Cross Origin Resource Sharing (CORS) to avoid the error. The request is below. Am I using the wrong adaptor?
var dataManager = ej.DataManager({
url: urlStr,
adaptor: new ej.WebApiAdaptor()
});
$("#GridMaster").ejGrid({
dataSource: dataManager,
allowSelection: true,
selectionType: "multiple",
allowPaging: true,
enablePaging: true,
pageSettings: { pageSize: 20 }
});