Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to embed my own video player in Facebook?

Is it possible to embed my own video player in Facebook, so I can see the video directly in the timeline, like all the YouTube videos?

Are there any metatags I need to include in the <head> section of my site?

like image 600
Simon Thomsen Avatar asked Jan 04 '11 08:01

Simon Thomsen


2 Answers

To add to the other answers, a recent developer post from Facebook (which I can't seem to find at the moment) inferred that whitelisting was no longer necessary. I did it anyway. Takes about a week.

You need to use the Open Graph protocol. Info on embedding video is at the bottom of this page: http://developers.facebook.com/docs/opengraph/

This is what we found through experimentation (which will certainly change in the future):

  • The player must be a flash player.
  • It must be an https link.
  • You can add optional flashvars as parameters.

An example og:video tag from our website:

<meta property="og:video" content="https://indieflix.com/media/swf/player.swf?bufferlength=3&lightcolor=FFFFFF&autostart=true&file=http%3A%2F%2Findieflix.com%2Fstreamer%2Fhdtrailer%2F32310_320x180.mp4&provider=http&frontcolor=CCCCCC&image=http%3A%2F%2Fcdn.indieflix.com%2Ffilms%2Fimages%2Flarge%2F32310.jpg&backcolor=333333" />
like image 198
Dave Avatar answered Sep 24 '22 22:09

Dave


You must first get your Flash player approved by submitting a video embed whitelist request.

Once this is approved, which took 4 hours for me when I look back on emails from my request, your player will be able to be shown just as YouTube videos are. You can then use the Facebook Share help guide which fire mentioned in his reply. Also, another helpful thing is the URL Linter which tells you how Facebook is interpreting the metadata on your pages.

like image 42
larsen161 Avatar answered Sep 24 '22 22:09

larsen161