wcf - Ajax POST request to ODATA service throws Invalid HTTP status code 501 -


i have following code wish use inserting record entity of odata service. post request throws xmlhttprequest cannot load invalid http status code 501.

apparently request works fine. can suggest way find out problem ? wcf service has problem ?

            var data = { application_id: 777 , user_id: 'test' };             var data = json.stringify(data);              $.ajax({                 type: 'post',                 contenttype: 'application/json; charset=utf-8',                 datatype: 'json',                 url: odataurl + 'application_admins',                 data: data,                 beforesend: function (xmlhttprequest) {                     xmlhttprequest.setrequestheader("accept", "application/json");                 },                 success: function (data, textstatus, xmlhttprequest) {                     account = data.d;                 },                 error: function (xmlhttprequest, textstatus, errorthrown) {                 }             }); 


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

python - PIL cannot identify image file for io.BytesIO object -

java - disabling a node without disable its children in javafx -