javascript - oauth twitter not working in android devices -
i created twitter client app in cordova using oauth protocol. in windows phone, app fetching request token , retrieving tweets. in android device,fetch request token not working. receiving error {"text":"", "xml":"", requestheaders": {}, "responseheaders": {shouldinterceptrequest}}
. using same code both platforms.
i used following code fetching token:
var oauth = oauth({ consumerkey: "xxxx", // replace here consumer key or api key consumersecret: "xxxx", // replace here consumer secret or api secret accesstoken: "xxxx", accesstokensecret: "xxxx", callbackurl: "http://twitter.com", requesttokenurl: "https://api.twitter.com/oauth/request_token", authorizationurl: "https://api.twitter.com/oauth/authenticate", accesstokenurl: "https://api.twitter.com/oauth/access_token" }); function onload() { oauth.fetchrequesttoken(function (url) { alert("opening request token url: " + url); login(url); }, function (data) { alert(json.stringify(data)); });
Comments
Post a Comment