Youtube Video Download In Milky Way »  Show posts from    to     

Icy Phoenix


phpBB 3 MODS And Styles (Not Compatible With phpBB 3.1) - Youtube Video Download In Milky Way



BluffMaster [ Mon 05 Jan, 2009 13:06 ]
Post subject: Youtube Video Download In Milky Way
Hi

I would like to have the youtube video downloader integerated in the milkyway style. I know it would use a custom page. but im a beginner and i failed in making one.

i would really appreciate if someone could tell me how to get it working in the milkyway style.


i think the form to input youtube link should be in the CustomYoutube.html (custom template file):
Code: [Hide] [Select]
<form method='post' action=''>
<input name='video' type='text' class='textbox' size="78"/>
<input type='submit' name='submit'value="Get it!" class="button">
</form>


and the link getting part should be in the CustomYoutube.php (custom php file):
Code: [Hide] [Select]
<?
if(eregi('youtube.com',$_POST['video'])){
$video="$_POST[video]";
$video2 = explode("watch?v=", $video);
$video2 = explode("&", $video2[1]);
$video2 = $video2[0];
$source = file_get_contents($video);

preg_match("/var fullscreenUrl = '(.*?)';/is", $source, $link);
$link=str_replace('/','',$link[1]);
$link=str_replace("watch_fullscreen?",'',$link);
$title = explode("<title>", $source);
$title = explode("</title>", $title[1]);
$title=str_replace("YouTube - ","",$title[0]);
$pic="http://img.youtube.com/vi/$video2/default.jpg";

echo"<br><b>$title</b><br><br><img src="$pic"><br><br><a href="http://www.youtube.com/get_video?$link">Download</a>";
}

?>




here's a link to the original script:

Code: [Hide] [Select]
http://rapidshare.com/files/177648981/Youtube_Downloader_v2__Beta_.rar



thanks




Powered by Icy Phoenix