[Solved] InvalidContent to try upload video with abraham library

video
media-upload
php

#1

hi community, in my script is impossible upload a video (your video.mp4 example of @abraham library), please, you can help me ?

my code :

$file_path = DIR . ‘/video.mp4’;
$result = $connection->upload(‘media/upload’, array(‘media’ => $file_path, ‘media_type’ => ‘video/mp4’), true);
var_dump($result );

this return

stdClass Object
(
    [request] => /1.1/media/upload.json
    [error] => InvalidContent.
)

#2

Can you upload the file through the Twitter website? If so are you 100 % sure the file path is correct? If so please post a link to the video somewhere that won’t convert/compress it so I can try it out.


#3

hi, in the web version is uploaded without problem.

this is my structure folder, my root folder is hely . … (screenshot). http://i.imgur.com/pSn0FF0.png

with the codebird library upload is successfull and you can view the video in @helymiguel

but i want use your library @abraham


#4

the video is: http://www.sample-videos.com/video/mp4/720/big_buck_bunny_720p_1mb.mp4


#5

wow ! sorry @abraham, i was confused . . .in the twitter web version not is possible upload …

message : Your media file is not compatible !

i try with a new video . . .

a question . . . . when i post a video , i can use in_reply_to_status_id ???


#6

POST statuses/update supports multiple parameters including in_reply_to_status_id and media_ids.


#7

yeah! solved ! thank you @abraham , the problem was in the video format

all fine (y)


#8