Created
December 13, 2013 23:23
-
-
Save netsuite/7953323 to your computer and use it in GitHub Desktop.
ajax cross domain jsonp call
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Note: | |
// we have to rap the response like this: | |
// response.write(callback + "(" +JSON.stringify(searchresults) +")"); | |
jQuery.ajax({ | |
url: 'https://', | |
dataType: 'jsonp', | |
crossDomain: true, | |
success: function(data) { | |
console.dir(data) | |
}, | |
error: function(e) { | |
console.log(e.message) | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment