JSFiddle - React, Tailwind, and code Playground
by Abid Shaik
HTML
<!-- Simple POST to Web Service -->
<div id="result">Result</div>
JavaScript
<!-- Simple POST to Web Service -->
$(document).ready(function() {
$.ajax({
url: "https://shearwater.brightdoor.com/brightbase/wsbrightdoor.asmx/CreateContact", type: "POST",
data: "clientID=1¢erID=1&username=p11creative&password=PASSWORD&firstname=BrightDoorDev&middlename=&lastname=POSTTestFRomJQ&suffix=&company=&spousefirst=&spouselast=&primaryhomephone=&primaryworkphone=&primaryotherphone=&secondaryhomephone=&secondaryworkphone=&secondaryotherphone=&primaryemailhome=&primaryemailwork=&primaryemailother=&secondaryemailhome=&secondaryemailwork=&secondaryemailother=&address=&address2=&city=&state=&zip=&country=&contactstatusid=6&initialContactTypeId=6&preferredcontactmethod=Email&primaryleadsourceid=54&secondaryleadsourceid=0&primaryagentid=8&secondaryagentid=0&contactInterestId=&addToTour=False&contactpassword=&contactattributes=",
success: function(xmlRes, sMsg, Obj) {
//console.log(xmlRes);console.log(sMsg);console.log(Obj);
$("#result").html("POST Async request, Created Contact ID : " + Obj.responseText);
},
failure: function(a, b, c) {
console.log(a);
console.log(b);
console.log(c);
}
});
});