Importing a YouTube Video Feed into Media Module
Last updated on
30 August 2018
Drupal 7 will no longer be supported after January 5, 2025. Learn more and find resources for Drupal 7 sites
Here's a quick guide to importing video files from Youtube into Media nodes.
You will need to have the following modules enabled:
- Media (the 7.x-2.x branch is required)
- Media Internet Sources (comes with Media)
- Media: Youtube
- Feeds module and its dependencies
- Media Feeds
Recommended:
- MediaFront player (for playing the video)
I believe there are other players out there that could work though.
- Create a node type with a Multimedia asset field or a file field. (I called mine "Video".) Set it to accept content with the youtube:// URI scheme.
- Add and configure a Media Player field (from MediaFront) - optional. Without this, the video will not show up on the node.
- Create a feed importer, using SimplePie preferably.
- Attach the feed importer to a content type - it only requires a Title field.
- Set the mapping on the feed importer to go from Item URL (link) to Video (media_internet)
- Save the mapping.
- Create a node with a Youtube RSS URL as the feed URL, something like
http://gdata.youtube.com/feeds/api/users/<username>/uploads
- Click the Import tab to import content from the RSS feed.
Note that I also tried using the Feeds: Youtube module on a Youtube Data feed but that did not work for me. If anyone can get this to work, please update this page accordingly.
Help improve this page
Page status: No known problems
You can:
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion