-
-
Save Noah-Huppert/7cb330e3889fb26ff02f to your computer and use it in GitHub Desktop.
This file contains 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
Error: | |
XMLHttpRequest cannot load http://sandbox.evernote.com/oauth. | |
The request was redirected to 'https://sandbox.evernote.com/oauth', | |
which is disallowed for cross-origin requests that require preflight. | |
Code: | |
//Evernote | |
var hostName = "http://sandbox.evernote.com"; | |
///Change to http://www.evernote.com for production | |
var | |
options, oauth; | |
options = { | |
consumerKey : '**********', | |
consumerSecret : '************', | |
callbackUrl : 'portal.php', | |
signatureMethod : "HMAC-SHA1", | |
}; | |
oauth = OAuth(options); | |
oauth.request({ | |
'method' : 'GET', | |
'url' : hostName + '/oauth', | |
'success' : success, | |
'failure' : failure | |
}); | |
function success() { | |
} | |
function failure() { | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment