35
The F.A.T. Manual
RollTube – The Rick Roll Firefox Extension Source code // // // // //
==UserScript== @name Roll-Tube @namespace http://fffff.at/rickroll-the-firefox-addon @description You've been rick rolled! ==/UserScript==
// // Originally written by Theodore Watson of http://fffff.at/theo-watson // Licensed for unlimited modification and redistribution // // This is a 'internet art' extension and should not be installed on any one else machines // as it might end up in them getting fired for inappropriate rick rollidge action (function() { var autoplay = false; var id = "gQCOQ63otnk"; if(autoplay){ id+= "&autoplay=1"; } var objects = document.getElementsByTagName('object'); for (var i=0; i< objects.length; i++){ var handle = objects[i].getElementsByTagName("param"); if(objects[i].getElementsByTagName("param") ){ var foundVideo = false; var w = 425; var h = 355; var source =
handle[0].getAttribute("value");
if(source.indexOf('youtube.com') != -1){ foundVideo = true; w = objects[i].getAttribute("width"); h = objects[i].getAttribute("height"); } var dataH; if( !foundVideo && ( (dataH = != null )){
objects[i].getAttribute("data") )
if(dataH.indexOf('youtube.com') != -1){ foundVideo = true; w = objects[i].getAttribute("width"); h = objects[i].getAttribute("height"); } } if( !foundVideo ){ var embedH =