Working with video

Using oEmbed to share and embed videos

Along with the manual ways of embedding videos from TwentyThree, we support oEmbed to make it easier and more flexible to embed content from your video website.

oEmbed is the recommended way to create embed codes and resolve other meta data from URLs.

What is oEmbed?

This standard is designed to allow an embedded representation of a URL on third party sites—or simply for developers needing to build embed snippets manually from IDs, tokens etc. The normal use case for oEmbed is allowing users in a content management system or other integrating software to simply copy-paste a direct URL to content into the integration. After this, developers will be able to retrieve not only a current embed code, but also control the player style and size along while getting access to basic information about the video. (This info can then be used to query the API for all available metadata if needed.)

You can read more about the concept on Webmonkey.

Using oEmbed with TwentyThree

Data can be accessed in JSON or XML and with a number of extra parameters:

This oEmbed mechanism supports resolving URLs for videos, channels and tags.

Using oEmbed with WordPress

It is common to want to embed videos from TwentyThree into a WordPress blog. This can be rather tricky to achieve since WordPress doesn't allow <iframe> embeds out of the box. Instead you can use oEmbed for the purpose.

To enable oEmbed for you video website domain, add this to your theme's functions.php (while remembering to replace with your correct domain):

wp_oembed_add_provider( '*', 
  '' );

If you can't add code directly to your WP theme, you can choose to enable oEmbed auto-discovery by installing this plugin. Be sure to read the security notes in the plugin description before doing so though.

Can't find what you're looking for?