oscarotero / Embed

Get info from any web service or page
MIT License
2.09k stars 312 forks source link

Google Drive support #408

Open garbinmarcelo opened 3 years ago

garbinmarcelo commented 3 years ago

Hello, I recently discovered that Google Drive has a video player and embed sharing (via iframe) of videos.

I would like to know if this package would support this feature, in the case of using video links from Google Drive.

It would be possible? If so, how could you do it?

Thanks

oscarotero commented 3 years ago

Yes, it's possible, but I don't have enough time to do that. If you (or anyone else) want to work on this, a pull request is very appreciated.

The way to implement this is by creating a new adapter for Google. You can see the existing adapters for inspiration: https://github.com/oscarotero/Embed/tree/master/src/Adapters (for example, Flickr has an adapter to provide a fallback way to detect the embed code).

Then, you have to register the adapter here: https://github.com/oscarotero/Embed/blob/master/src/ExtractorFactory.php#L14, indicating the domain in which the adapter will be loaded.

garbinmarcelo commented 3 years ago

Ok, this month I also have tight deadlines for project delivery, but if I can, next month I work on it. =)

Can you leave this issue open?

Thanks