0
嗨我现在用的是以下几点:问题与API发送私信给某人的Twitter
function confirm($x, $y)
{
$inerlevelWatch = $x;
$NewDirectMessage = $y;
$directmessconect = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET, $currentTwitteroauth, $currentTwitteroauthsecret);
$parameters = array('screen_name' => $inerlevelWatch, 'text' => $NewDirectMessage);
$method = 'direct_messages/new';
$directmessconect->post($method, $parameters);
}
所以我给$innerlevelWatch
一个SCREEN_NAME因此,可以说,Joe
比传递了新的直接消息到$NewDirectMessage
='testing
'。我创建了新的连接,只是为了在此函数内部发送消息并设置参数。设置方法,然后进行发布。
问题是,它似乎并没有真正发送,我不知道为什么,所以如果你能给我一只手,我将不胜感激!