From fdc24888276a46008068cd243cfc05eb3fbb46b7 Mon Sep 17 00:00:00 2001 From: mattn Date: Fri, 20 Jun 2008 07:04:23 +0000 Subject: GETからPOSTに修正(API制限回避) git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@14289 d0d07461-0603-4401-acd4-de1884942a52 --- twitter.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/twitter.js b/twitter.js index 1319a47..38ea2e1 100644 --- a/twitter.js +++ b/twitter.js @@ -49,7 +49,7 @@ } function showTwitterReply(username, password){ var xhr = new XMLHttpRequest(); - xhr.open("GET", "http://twitter.com/statuses/replies.json", false, username, password); + xhr.open("POST", "http://twitter.com/statuses/replies.json", false, username, password); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.send(null); var statuses = window.eval(xhr.responseText); @@ -78,9 +78,9 @@ var xhr = new XMLHttpRequest(); var endPoint = target ? "http://twitter.com/statuses/user_timeline/" + target + ".json" : "http://twitter.com/statuses/friends_timeline.json"; - xhr.open("GET", endPoint, false, username, password); + xhr.open("POST", endPoint, false, username, password); // for debug - //xhr.open("GET", "http://twitter.com/statuses/user_timeline/otsune.json", false, username, password); + //xhr.open("POST", "http://twitter.com/statuses/user_timeline/otsune.json", false, username, password); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.send(null); var statuses = window.eval(xhr.responseText); -- cgit v1.2.3