jQuery JIRA Post not working in IE/FF

jQuery JIRA Post not working in IE/FF

I am trying to post data to JIRA and it seems to only work in Chrome. Does not work in IE/FF. Please Help. I think this has something to do with the ajax call setup. Not sure what I need to get this to work.

  1. $('#new_request > footer > input').bind('click', function(e) { var subjects = $("#request_subject").val(); var descriptions = $("#request_description").val(); var attachments = $(".upload-link").attr('href'); var cust1 = $("#request_custom_fields_27736417").val(); var cust2 = $("#request_custom_fields_27745068").val(); var cust3 = $("#request_custom_fields_27736427").val(); var cust4 = $("#request_custom_fields_27745078").val(); var cust5 = $("#request_custom_fields_27736437").val(); var cust6 = $("#request_custom_fields_27638038").val(); var cust7 = $("#request_custom_fields_27638118").val(); var cust8 = $("#request_custom_fields_27632077").val(); var cust9 = $("#request_custom_fields_27632087").val(); if (subjects !== null || descriptions !== null){ function CreateJIRATicket(summary,description, custom1,custom2,custom3,custom4,custom5,custom6,custom7,custom8,custom9,custom10 ) { var JIRAusername = "YouruserName"; var JIRApassword = "YourPassword"; var jsondata = {"fields": { "project":{ "key": "ZDI"}, "summary": summary, "description":description, "issuetype": {"name": "Story" }, "customfield_11200" : custom1, "customfield_11201" : custom2, "customfield_11202" : custom3, "customfield_11203" : custom4, "customfield_11204" : custom5, "customfield_11205" : custom6, "customfield_11206" : custom7, "customfield_11207" : custom8, "customfield_11208" : custom9, "customfield_11209" : custom10 } }; $.ajax({ type: "POST", crossDomain: true, contentType:"application/json; charset=utf-8", dataType: "json", username: JIRAusername, password: JIRApassword, data: JSON.stringify(jsondata), url: "https://jira.yourdomain.com/rest/api/2/issue", xhrFields: { "withCredentials": true }, success: function (ticket){ console.log('Page saved!', ticket); }, error : function(xhr, errorText){ console.log('Error '+ xhr.responseText); } })//end ajax post JIRA  } } CreateJIRATicket(subjects, descriptions, cust1, cust2, cust3, cust4, cust5, cust6, cust7, cust8, cust9, attachments); }); }