title: jQuery ajax request error: callback not called
body: <pre><code>window.MyCallback = function (data) {
     console.log(data);
  };
  
  $(document).ready(function () {
  
      $.ajax({
              type: 'GET',
              url: 'http://xxx.xxx.xxx.xx/MyService/Service.svc/MyMethod',
              contentType: 'application/jsonp',
              crossdomain: true,
              dataType: "jsonp",
              data: { 'username': 'Jack' },
              crossDomain: true,
              jsonpCallback: 'MyCallback',
              success: function (txt) {
                  console.log(txt);
              },
              error: function (xhr, status, err) {
                  console.log(status, err);
              }
      });
  });
  </code></pre>
  
  <p>I always get the error: <code>MyCallback was not called.</code></p>