开发者

Twitter PHP - URL not encoded in tweet

I'm trying to post to Twitter using the Twitter PHP SDK twitter-async my tweets include a URL in them that doesn't seem to be getting encoded. How can I make the URLs show properly when tweeted?

I call this function in the SDK

function postTweet($tweet) {
  $this->twitterObj->post('/statuses/update.json', arra开发者_运维知识库y('status' => $tweet));            
}

There's not much to it really.


In the end it was simply an issue with Twitter not recognizing my local URL as an url, when I tested changing to my production site it worked fine.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜