Skip to content

Instantly share code, notes, and snippets.

@timrwood
Last active November 21, 2019 15:22
Show Gist options
  • Save timrwood/10746992 to your computer and use it in GitHub Desktop.
Save timrwood/10746992 to your computer and use it in GitHub Desktop.
YouTube and Vimeo video player popout bookmarklett
javascript:!function(){var h=location.href,y=h.match(/(youtu.be\/|v\/|u\/\w\/|embed\/|v=)([^#\&\? ]*).*/),v=h.match(/(vimeo.com\/)([^#\&\? ]*)/);y=y&&'http://www.youtube.com/watch_popup/?v='+y[2];v=v&&'http://player.vimeo.com/video/'+v[2];window.open(y||v,"_blank","height=345,width=560");}()
@majman
Copy link

majman commented Feb 6, 2015

thanks for that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment