我正在尝试通过Twitter API发布消息,只要我有一个简单的文本字符串,它就会起作用,但是,只要我在我的消息中添加了一个URL就不会发布。我需要逃避一些角色吗?
WORKS:
$connection->post('statuses/update', array('status' => 'Trying out a new online tool with a monthly complimentary subscription. via @mySite'));
不工作:
$connection->post('statuses/update', array('status' => 'Trying out a new online tool with a monthly complimentary subscription at: http://mysite.org via @mySite'));
答案 0 :(得分:0)
我认为你需要在邮件中进行URL编码。
尝试:
$connection->post('statuses/update', array('status' => urlencode('Trying out a new online tool with a monthly complimentary subscription at: http://mysite.org via @mySite')));