1
$request_data = http_build_query(
array(
'oauth_token' => 'xxx',
'api_key' => 'xxx',
'type' => 'hello',
'title' => 'this is title',
'body' => 'this is body',
'generator' => 'API example'
)
);
// Send the POST request (with cURL)
$c = curl_init('http://api.tumblr.com/v2/blog/abc.tumblr.com/post');
curl_setopt($c, CURLOPT_POST, true);
curl_setopt($c, CURLOPT_POSTFIELDS, $request_data);
curl_setopt($c, CURLOPT_RETURNTRANSFER, true);
$result = curl_exec($c);
$status = curl_getinfo($c, CURLINFO_HTTP_CODE);
curl_close($c);
しかし実行しません... 私を手伝ってください!tumblrAPI V2 oauth phpで新しい投稿を追加するには