sampotts / plyr

A simple HTML5, YouTube and Vimeo player
https://plyr.io
MIT License
26.51k stars 2.93k forks source link

How to stream vdo mp4 from Google Drive #1787

Open naipol168 opened 4 years ago

naipol168 commented 4 years ago

Hello, I try to start vdo streaming from Google Drive and any cloud. But I can not find the way who to make it play the vdo. Please advise with thnaks.

Best regards, CK

ghost commented 4 years ago

Plyr will most likely never have the ability to stream from Google Drive. Google has multiple checks in place to ensure that videos are only watched through their website and player.

naipol168 commented 4 years ago

Thank you for your idea

CodeDruid13 commented 4 years ago

Hello, I try to start vdo streaming from Google Drive and any cloud. But I can not find the way who to make it play the vdo. Please advise with thnaks.

Best regards, CK

You need to use the api, the data returned should be authorized with the file id , or alternatively use the sharing link. Extract the text between

.../d/(This Text id)/edit...

link with a regex. Add it to the link

<source src="https://drive.google.com/uc?export=download&id=Extracted ID Here" type='video/webm'/>

and use as video source html component. Please note this only works with logged in google accounts. Otherwise you can't really stream with drive easily

reubano commented 3 years ago

FYI, Google Drive supports embedding. See here.

<iframe src="https://drive.google.com/file/d/<FILE_ID>/preview" width="640" height="480"></iframe>

CR #290

ctsstc commented 3 years ago

It's interesting that just a little over a year ago this was a feature in drive (grab an embed link): https://www.colby.edu/acits/2020/01/30/how-to-embed-a-video-from-google-drive/ As you can see though and as explained above it's just a simple iframe.