Guide to Independent Video Hosting

Hybrid Approaches for Video in Drupal

This chapter looks at just two techniques for a Hybrid approach to video in Drupal, using well-supported modules. Specifically, incorporating external video files into a player using the Linkmodule, and merging uploaded video files and video from external services using the Media module.

Hands On: Incorporating External Video Files

To start, install the Link module.

Add a link field to a content type and give it a name like Video Link.  

 

Then set up a Link field to use Media Element Video in the Manage Display section of the Content Type.  

Click Save.

Test this set up by first pasting in a URL from an external file hosting service like Archive.org. 

If we preview this, we see it works well to create a player that is streaming the external video file.  

Hands On: Displaying Video from Services and Uploaded Video  

To use it, install and enable the Media module in the normal way then some helper modules extending media. To test it, try media_youtube and media_vimeo to get you started, but there are many more available.

Add a File field to content type, and select Media File Selector as widget type.  

Configure file types allowed for uploaded video, select Video for Allowed remote media type, select Youtube and Vimeo, and enter other details like max file size.  

When we add our video content, now we can see a Select Media button.  

This gives us a flexible dialogue box where we can Upload a new video, enter a URL or Embed code from one of the video service, or choose a video already in our Media Library

Try either an upload or a web link.  

To display the video, we need to choose different options in the Manage Display tab of our File field.

For video coming in from services like YouTube and Vimeo, choose Rendered File.

However, for uploaded video, we need to select MediaElement Video.