I want to get the video ID of a Youtube URL, but often the URL is condensed into a Tiny URL when being shared.
For example, I have a script that gets the Youtube video's thumbnail based on its video ID =
<?php $vlog = "OeqlkEymQ94"; ?>
<img src="http://img.youtube.com/vi/<?=$vlog;?>/0.jpg" alt="" />
This is easy to get when the URL I'm extracting it from is
http://www.youtube.com/watch?v=OeqlkEymQ94
but sometimes the URL is a tiny URL so I have to figure out how to return the real URL so I can use it.
http://tinyurl.com/kmx9zt6
Is it possible to retreive the real URL of a URL through PHP?