Embedding and Sharing Video in SharePoint. Part Two: Posting embedded code, support for different Video Providers, Preview view

Introduction

In previous post we have discussed  approach on how to embed video into SharePoint from YouTube. Custom List Video Links were used for storing embedded video properties and Computed Field for rendering Video player.
This time we will extend our solution with the following capabilities:

  • Support for different video providers listed in  oEmbed
  • Preview view for displaying video arranged in list
  • Alternative mode for posting the embed code for video into SharePoint

Support for different video providers

In addition to embed code using iframe, another options also available now. Some providers listed in oEmbed specification use object element for embedding code.

Table 1. Support for Video Providers listed in oEmbed specification

Provider Name Embedded Mode
YouTube IFrame, Object(YouTube)
Viddler -
Qik Object(Qik)
Revision3 IFrame
Hulu IFrame
Vimeo IFrame
CollegeHumor Object(CollegeHumor)
Jest Object(Jest)
CircuitLab -

Alternative mode for posting embedded code

Additionally to existing mode for embedding video code, the approach described below allows to paste the embed code as it was generated by Provider. Let’s take a look at the common usage scenario:

  • Generate and copy the embed code on the Provider website
  • Select Embed Code from New Item for Video Links List

  • In New Form for Video Links List paste the embed code and fill in comments if needed as shown below

For displaying video player the same (see previous post for details) Computed Field EmbeddedVideoOnForm field is used

Preview view for displaying video

In addition to default view (video player items with details), Preview view is intended to display items arranged by columns as shown below

Implementation

To paste the embed code we define Embed Code Content Type

where field EmbedCode for storing the embed code  is used

As was noted earlier, for displaying video player the same (see previous post for details) Computed Field EmbeddedVideoOnForm field is used, below is presented complete XSLT style sheet for  rendering of a field on a List View

References

About these ads

4 thoughts on “Embedding and Sharing Video in SharePoint. Part Two: Posting embedded code, support for different Video Providers, Preview view

  1. Pingback: Embedding and Sharing Video in SharePoint. Part Three: Aggregating Video Feeds and utilizing API | vgrem's Blog

  2. Hi Vadim,
    Your solution is fantasctic. It works very well for me. Thank you very much.
    However, I need to embed videos in sharepoint online! As you may know it is not possible ot deply farm solutions in sharepoint online (only sandboxed solutions are supported). I was trying to create a sandboxed solution and use your code inside but I was not successful.
    Do you have sandboxed version of you solution?

    Thank you again.

  3. Pingback: Embedding Video to a SharePoint Library | Yet Another SharePoint Blog

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s