通过API设置Twitter状态(不带oAuth)
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了通过API设置Twitter状态(不带oAuth)相关的知识,希望对你有一定的参考价值。
This script works good condition, and not use "oAuth".Your should get username and password with cleartext (standart html controls) without authentication and just add them into variables in your code...
(twitter_username and twitter_password)
And also get status from textbox and set variable named "new_status"
Response.Buffer = True Dim xml Set xml = Server.CreateObject("Microsoft.XMLHTTP") twitter_username = "YOUR USERNAME" 'change to your twitter username twitter_password = "YOUR PASSWORD" 'change to your twitter password new_status = "YOUR STATUS" 'change to your new status xml.Open "POST", "http://" & twitter_username & ":" & twitter_password & "@twitter.com/statuses/update.xml?status=" & server.URLencode(new_status), False xml.setRequestHeader "Content-Type", "content=text/html; charset=iso-8859-1" xml.Send Response.Write xml.responseText 'view Twitter's response Set xml = Nothing
以上是关于通过API设置Twitter状态(不带oAuth)的主要内容,如果未能解决你的问题,请参考以下文章
通过 ServiceStack api 使用 Linq2Twitter 和缓存的 OAuth 令牌
我们可以从 Twitter oauth API 获取电子邮件 ID 吗?