title: how to use jQuery ajax to fetch json data via https POST method?
body: <p>I want to use jQuery ajax method to validate login, the web service is provided by third-party via https POST method.</p>
  
  <p>I use the following code, but it doesn't work.</p>
  
  <pre><code>$.ajax({
  type: "POST",
  
  dataType: 'json',
  contentType:'application/json',
  url: "https://salesforce login web service",
  crossDomain:true,
  data: {un:"bohan",pw:"123456"},
  success: function(data) {
  alert('success!'); // or not!
  },
  error:function (xhr, ajaxOptions, thrownError){
              alert(xhr.status+" : "+thrownError); // 0
  
          }
  });
  </code></pre>
  
  <p>I think it may be caused by AJAX cross-domain related issue. How can I do with it? who can give me some suggestions? thank you so much.</p>