Estoy haciendo un archivo, que saca de Youtube el FLV del video... y fuerzo la descarga de ésta manera:
Código PHP:
<?
$ytp=file_get_contents("http://youtube.com/watch?v=".$_REQUEST['q']);
// echo '<pre>'.$ytp.'</pre>';
preg_match('%/player2.swf(.+)", "m%',$ytp,$video_url);
$video_url="http://youtube.com/get_video?video_id=".$video_url[1];
$video_url = str_replace("get_video","player2.swf",$video_url);
$videiitoxxxx = $video_url;
$videiitoxxxx = str_replace("player2.swf?video_id=?hl=en&BASE_YT_URL=http://youtube.com/&","get_video?",$videiitoxxxx);
$filename = $videiitoxxxx;
$f = $videiitoxxxx;
header("Content-type: video/flv");
header("Content-Disposition: attachment; filename=\"".basename($filename)."\";" );
header("Content-Transfer-Encoding: binary");
header("Content-Length: ".filesize($filename));
readfile("$filename");
exit();
?>
Si alguien me puede ayudar, pues seria de mucha ayuda!! y quizás luego posteo el reproductor por aquí para que lo tengan los otros webmasters en su web tambien
Saludos a todos!