Created
May 29, 2012 19:39
-
-
Save amccloud/2830243 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
var authorize = function(username, key) { | |
jQuery.ajaxSetup({ | |
beforeSend: function(xhr) { | |
xhr.setRequestHeader('Authorization', 'ApiKey ' + username + ':' + key); | |
return xhr; | |
} | |
}); | |
}; | |
authorize('amccloud', '204db7bcfafb2deb7506b89eb3b9b715b09905c8'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment