My goal: I am trying to allow users to embed a link to a Youtube video in my site, while giving me control over the player\'s settings.
I would like to do this by only a
This is what youtube uses:
Then just use a regexp to change the link from:
http://www.youtube.com/watch?v=zb-gmJVW5lw
into:
http://www.youtube.com/embed/zb-gmJVW5lw
Here's a proof of concept regexp for matching regular youtube links:
And here's a proof of concept regexp for matching youtu.be links:
Note that the embed url can also be loaded in the browser which opens a page where the video is fullscreen.