By possumboy
—
Last update
Aug 30, 2008
—
Installed
1,015 times.
// ==UserScript==
// @name SimpleYoutubeDownloader
// @description A simple youtube video downloader. Doesnt require you to load a new page - just downloads in the mp4 format. It's simple!
// @include http://*.youtube.com/watch?v=*&*
// @include http://*.youtube.com/watch?v=*
// @include http://youtube.com/watch?v=*
// @include http://youtube.com/watch?v=*&*
// ==/UserScript==
possvid = ""+window.location;
possvidd = possvid.split("v=");
possviddd = possvidd[1].split("&");
dlBox = document.createElement("div");
b = document.getElementsByTagName("body")[0];
dlBox.id = 'tube_dlBox';
dlBox.setAttribute("style", "position: fixed; right: 5px; bottom: 10px; z-index: 100000;");
dlI = document.createElement("img");
dlI.setAttribute("src", "http://i36.tinypic.com/308uq2s.gif");
dlI.setAttribute("style", "position: relative; vertical-align:middle; margin-top: -2px; margin-right: 2px;");
t = b.innerHTML;
t = t.split("&t=");
t = t[1].split("&");
t = t[0];
dlA = document.createElement("a");
dlA.setAttribute("href", 'http://www.youtube.com/get_video?video_id='+possviddd[0]+'&fmt=18&t='+t+'');
dlA.setAttribute("style", "font-family:Arial;font-size:12px;font-weight:bold;color:#1F85C1 !important;text-align:center;background-color: #DFF1FD;border:1px solid #B6D9EE;padding:5px;");
text = document.createTextNode("Download");
dlA.appendChild(dlI);
dlA.appendChild(text);
dlBox.appendChild(dlA);
b.appendChild(dlBox);