Getting a video from S3 and Uploading to YouTube in PHP

后端 未结 4 1105
忘了有多久
忘了有多久 2021-02-06 11:02

I have some code working that uploads a video file up to YouTube:

$yt = new Zend_Gdata_YouTube($httpClient);

// create a new VideoEntry object
$myVideoEntry = n         


        
4条回答
  •  無奈伤痛
    2021-02-06 11:22

    The "MediaFileSource" must be a real file. It won't take a URL, so you will need to copy the videos to your server from S3, before sending them to YouTube.

    You can probably get away with the "shell_exec" if your usage is light, but for a variety of reasons its probably better to use either the Zend S3 Service, or cURL to pull files from S3.

提交回复
热议问题