I am trying to post data using the below html form. The code works fine in chrome, However, When I make a post call to the server using the below html form from IE11, I get the "SCRIPT7002: XMLHttpRequest: Network Error 0x2ef3, Could not complete the operation due to error 00002ef3." error.
HTML file:
<!DOCTYPE html><html><head><script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script><script> $(document).ready(function(){ $("#send").click(function(){ $.ajax({ url:"https://ui-php.apps.pcfdev.prod.demo.int/api/?id=1233", type:"POST", data:JSON.stringify({username:'Something', credentials: 'credentials', key: '12345'}), contentType:"application/json; charset=utf-8", dataType:"json", success: function(){ console.log('Success'); } }); }); });</script></head><body><button id="send">Send</button></body></html>I also tried the solution mentioned in https://stackoverflow.com/questions/7096343/post-method-getting-converted-to-get-in-ie-9 but it didn't work