javascript - jQuery Ajax PUT not firing -


the following ajax works advertised in chrome. http put used trigger insertion of object restful api.

        $.ajax({             type: "put",             url: "/ajax/rest/team/create/",             datatype: "json",             processdata: false,             data: json.stringify(teamobject),             success: function (response) {                 teamobject = response.object;             }         });  

i note jquery api docs helpfully tell me put , delete may work not guaranteed in browsers. such problem.

how restful api supposed implemented on client side problem this?

edit: firebug tells me ff indeed issuing put, unknown reason it's dying before getting server. repeat, works fine in chrome.

edit: fiddler doesn't see ff attempt @ all. :(

i got following work.

var payload = json.stringify(teamobject) synchttp('/ajax/rest/team/create/', 'put', payload);  function synchttp(url,method,payload) {     var client = new xmlhttprequest();      client.open(method, url, false);     client.setrequestheader("content-type", "text/plain");     client.send(payload); } 

i'd rather use jquery roll own tho. :| if ever figures out, add answer , if works i'll accept it.

thanks.


Comments

Popular posts from this blog

Perl - how to grep a block of text from a file -

delphi - How to remove all the grips on a coolbar if I have several coolbands? -

javascript - Animating array of divs; only the final element is modified -