Skip to content

Instantly share code, notes, and snippets.

@calvinchoy
Last active April 4, 2020 08:38
Show Gist options
  • Save calvinchoy/f4144fd9afcf398f4c7c to your computer and use it in GitHub Desktop.
Save calvinchoy/f4144fd9afcf398f4c7c to your computer and use it in GitHub Desktop.
JS - simple jsonp call #jquery
$.ajax({
url: "url to the server processing code",
dataType: "jsonp",
contentType: "application/json",
data: JSON.stringify({}),
success: function(response) {
//response is json data returned from server side url
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment