Clone the Media Fragment from the page's URL to any embedded media on the page
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

Clone Media Fragment

This is a quick way to support URLs such as YouTube's time offset URLs. This snippet of Javascript will clone the page's Media Fragment to any embedded media on the page.

This is written in plain Javascript, and has no external dependencies.

Usage: Just include this Javascript file on your site. It will find any <video> and <audio> tags and set up the necessary event listeners.