-
Website
http://www.abdulqabiz.com/blog/ -
Original page
http://www.abdulqabiz.com/blog/archives/2007/05/31/update-getting-youtube-video-flv-url/ -
Subscribe
All Comments -
Community
-
Top Commenters
-
melanie12345
1 comment · 1 points
-
kanti
1 comment · 1 points
-
anuradhashinde2001
2 comments · 2 points
-
joeboxer
1 comment · 1 points
-
petkusj
2 comments · 1 points
-
-
Popular Threads
Howto Get Direct YouTube Video (FLV) URL
@mike: YouTube/Google both do HTTP 302/303 redirection. YouTube required "t" param along with video_id and it forwarded to one of their CDN server..
Things are dynamic in nature and I don't think, there is a hardlink (afaik), but you can save the video_ids and program your player in a way that it loads videos through either cache.googlevideo.com or old way (you would need t param).
-abdul
It is one step less to access the video from a Flash animation when you only have the video URI. The old way asks to first download the page was so boring.
This is really cool though. I just hope they don't close it
btw: i'm not downloading videos from youtube, i'm indexing them and streaming it directly over the web :-)
Although the URL you provided doesn't lets you download 'old' youtube ID's/video's.
Use this one instead:
http://rd.cache.l.google.com/get_video?video_id=
PS: Could be just IE again though, but the above link works for IE as well :)
i need some Help. i want to play youtube video from mediaPlayback player in flash. so what should i do for it . i also use your ActionScript2.0 in which splitting technique is uesd for flv url but it is not workng plz help out to et this prob
thanks
thanks
The closest I came was through the stream_get_meta_data() function, but even that only returned other get_video.php paths.
Is there any way to find the actual hard link to the flv file for youtube videos?
As for the filepath, that's the weird part. stream_get_meta_data SOMETIMES returns a hard path to the FLV.
Take, for example, http://youtube.com/watch?v=xCAeq5kE0Ko
Using the s_g_m_d() function, the following locations return:
http://lax-v284.lax.youtube.com/get_video?video...
http://cache.googlevideo.com/get_video?video_id...
http://sjc-v166.sjc.youtube.com/get_video?video...
and then, finally:
http://youtube-769.vo.llnwd.net/d1/01/F8/xCAeq5...
There is no rhyme or reason to which one returns, and if I put the function on a loop, I could wind up with a dozen pointers before the hard path comes back. Meanwhile other YouTube urls might return only the pointer and never the hard path.
It's looking more and more like I'll have to figure out how to make the AS just use the cache location. I just wish I could understand why the path returns sometimes but not all the time.
Look at Google-Video RSS feeds and filter for all videos uploaded to Google-Video, you get videos in different formats including flv.
-abdul
I'm a designer and I'm just looking for a simple way to play videos in a custom player... any chance you could dumb it down a bit for the coder-challenged?
@Colin: Right, there is no extension for file because YouTube/Google servers throw video/x-flv (video/flv) content-type...You can save it as .flv without any problem.
I just checked, URL with different video_id works. Not sure, why it's not working for you.
Thanks
-abdul
i created custom video player and i embeded the video player in my page.I want to play youtube video (i did'nt get the youtube filepath)
how should i play the video in my page.
yes, I noticed that cache.googlevideo.com started throwing BAD request from yesterday... and youve updated this post to point the fact out...
but here's a way around what google's done to prevent it.
http://cache.googlevideo.com/get_video?video_id... [WORKS]
http://cache.googlevideo.com/get_video?video_id... [DOES NOT WORK]
cheers :-)
add &origin;=youtube.com to the string ;-)
example
greets
bmxaction.net
http://cache.googlevideo.com/get_video?video_id...
Returns:
Bad Request
Your client has issued a malformed or illegal request.
Google cache links for youtube videos no longer work. Do you know if Google has issued any sort of statement on the matter?
@eee, Mike Troy: As per my understanding, videos uploaded after YouTube's acquisition by Google can be downloaded from Google-Cache (cache.google.com)...Other old videos are still on YouTube's CDN.
-abdul
I'm having a wierd issue here. The video's play perfect in the MediaPlayback component. But they don't in the FLVPlayBack component and i cant find why...?
Also i tried to use "http://cache.googlevideo.com/get_video?video_id=M0ODskdEPnQ&.flv"
but that dousn't work either.
Anyone an idea?
You might want to try it using other technique (using php proxy or actionscript code), both of them are mentioned on my blog...
Thanks
-abdul
example
http://cache.googlevideo.com/get_video?video_id...
It doesn't work on all youtube videos, but adding ( &origin;=1 ) after the cache url seems to do the trick. You can add any symbol, letter or number after the equals sign and it works.
The old way works on all videos. Enter the embedding code for the video in your browsers address bar. When it loads replace ( /swf/l.swf? ) with ( get_video? )
7usTgw-7XfM
it should now accept parameters passed to contentPath.
else{
_isRTMP = false;
_streamName = parseResults.streamName;
return (canReuse || connectHTTP());
}
It's not dynamic but a quick trick to get the path.
View it here >> "How to get the direct url path to .flv video files on YouTube for Free"
Hope this helps...
Others are more likely to earn more money from that php codes, you are a cool man !!!
BrightCove Videos
http://studio.brightcove.com/
the youtube way doesn't work for a video using the brightcove player
-abdul
how do i find out what the formatt is as i want to convert some of them for dvd or vcd, or are they not ment to b converted.
thanks pete
That's all!
it should now accept parameters passed to contentPath.
else{
_isRTMP = false;
_streamName = parseResults.streamName;
return (canReuse || connectHTTP());
}
I am using Flash CS3 on OS X and within NCmanager.as at line 276 it does not have an if statement. I found the NCmanager.as file in the directory Flash CS3>Configuration>Component Source>ActionScript 3.0>FLVPlayback>fl>video
I was able to get the urlhttp://cache.googlevideo.com/get_video?video... to playback using the Media Component in Actionscript 2.0 but can't get it to play with the Flvplayback component in either Actionscript 2 or 3. Can anyone figure how to play using FLVplayback component??
I have a cache-server that is caching youtube flv video. Somewhere in Feb 2008, I notice that youtube return new parameters on the URL for download...client ip address..signature...
This makes every individual download unique if the clients are of different ip. From my cache-server, all flv files are missed. Any ideas on this?
Thanks.
Example
Previously
http://cache.googlevideo.com/get_video?video_id...
Now
http://cache.googlevideo.com/get_video?video_id...
7usTgw-7XfM
the same
Is there anyway to bypass the filter and download the clip from youtube since all the youtube IP ranges have been snuffed out?
Just check out the following website
Enter the url and get your favorite clip
You can also check Auto-Download to D.L your stuff from the page.
Otherwise you'll be given a code.
http://kej.tw/flvretriever/
Hope this helps some of you.
Thank you Abdul this is a very nice code! too bad I just found it, while it was posted a LONG time ago!
I guess the "http://youtube.com/get_video.php" script is gone because I get no results whatsoever, only 404 error.
While if you run a query for: "http://youtube.com/v/AJRcOF7rEfQ" it works, but you won´t get te 't=' param anymore.
@Abdul
It seems your server does not accept any requests, I keep getting 403 error on all your examples.
can you please tell me how to do the same for myspace?
i mean how can i download files in flv format?
thanks
Salam.
however the only way to access that key is if you access a video from the normal link.
Maybe someone can write a PHP that grabs that......
i m creating a flex application with you tube videos
i m facing a problem for getting flv path from youtube path.
in xml youtube path is
http://www.youtube.com/v/AWa0w8gChmE?f=videos&a...
how can i get flv path from this path
can u help me