Today I was browsing digitaldomain.com and was amazed about the making of / behind the scenes (BTS) of computer generated effects, so I wanted to save these videos on my Harddisk.
Usually, a bookmark ('favelet') with the following code does the job to list embedded media*:
javascript:f=%5B%5D;for(i=0;(e=document.getElementsByTagName('embed')%5Bi%5D);i++)%20%7Bf%5Bf.length%5D=e.src;%7Dfor(i=0;(o=document.getElementsByTagName('object')%5Bi%5D);i++)%20%7B%09if%20(o.data)%20%7Bf%5Bf.length%5D=o.data;%7D%09else%20%7B%09%09for%20(j=0;p=o.getElementsByTagName('param')%5Bj%5D;j++)%20%7B%09%09%09if%20(p.name.toLowerCase()=='movie'%20%7C%7C%20p.name.toLowerCase()=='src'%20%7C%7C%20p.name.toLowerCase()=='href')%09%09%09f%5Bf.length%5D=p.value;%09%09%09%7D%09%09%7D%09%7Dm=/(mpg%7Cmpeg%7Cmov%7Cavi%7Cswf%7Casf%7Cwmv%7Cmp3%7Cram)$/i;for(i=0;(a=document.getElementsByTagName('a')%5Bi%5D);i++)%20%7B%09if%20(a.href%20&&%20m.test(a.href))%20%7B%20f%5Bf.length%5D=a.href;%7D%09%7Dr='%3Cdiv%20style=%22border:1px%20solid%20%23BBB;%20border-top-style:%20none;%20padding:%204px;%22%3E%3Cstrong%3EEmbedded%20Media:%3C'+'/strong%3E%3Cbr%20/%3ERight-click%20and%20save%20file(s)%20as:%20%3Cul%3E%5Cn';for%20(i=0;i%3Cf.length;i++)%7B%09n=f%5Bi%5D.substring(f%5Bi%5D.lastIndexOf('/')+1,f%5Bi%5D.length);%09if%20(n.indexOf('?')!=-1)%7Bn=n.substring(0,n.indexOf('?'));%7D%09r+='%3Cli%3E%3Ca%20href=%22'+f%5Bi%5D+'%22%3E'+n+'%3C'+'/a%3E%3C'+'/li%3E%5Cn';%09%7Dr+='%3C'+'/ul%3E%5Cn%3Ca%20href=%22javascript:;%22%20onclick=%22parentNode.parentNode.parentNode.removeChild(parentNode.parentNode);%22%3EDone%3C'+'/a%3E';d=document.createElement('div');d.innerHTML=r;d.style.cssText='font:%2010px/15px%20%22Lucida%20Grande%22,%20Geneva,%20Arial,%20sans-serif;%20text-align:%20left;%20position:%20absolute;%20top:%200;%20right:%2016px;%20z-index:%201000;%20border:%201px%20solid%20%23FFF;%20border-top-style:%20none;%20background-color:%20%23FFF;';void(document.body.appendChild(d));
This script takes the current page, examines the embedded media (movies, flash, etc.), and displays the links to the source files in the upper right corner. You can download them with a right-click, and "save as...". But somehow the script didn't work this time.
The HTML-source showed a lot of JavaScript, but no Quicktime file. So I took a second bookmark which is to view the rendered source*:
javascript:r='%3Cdiv%20style=%22border:1px%20solid%20%23BBB;%20border-top-style:%20none;%20padding:%204px;%22%3E%3Cstrong%3EViewing%20Rendered%20Source%20of:%3C'+'/strong%3E%3Cbr%20/%3E%20'+document.location;r+='%3Ctextarea%20style=%22font:%2010px/15px%20Monaco,%20monospace;%20display:%20block;%20overflow:%20auto;%22%20cols=%2280%22%20rows=%2220%22%20wrap=%22off%22%20readonly=%22readonly%22%3E'+document.body.parentNode.innerHTML+'%3C'+'/textarea%3E%3Ca%20href=%22javascript:;%22%20onclick=%22parentNode.parentNode.parentNode.removeChild(parentNode.parentNode);%22%3EDone%3C'+'/a%3E%3C'+'/div%3E';d=document.createElement('div');d.innerHTML=r;d.style.cssText='font:%2010px/15px%20%22Lucida%20Grande%22,%20Geneva,%20Arial,%20sans-serif;%20text-align:%20left;%20position:%20absolute;%20top:%200;%20right:%2016px;%20z-index:%201000;%20border:%201px%20solid%20%23FFF;%20border-top-style:%20none;%20background-color:%20%23FFF;';void(document.body.appendChild(d));
There I found an iframe (include frame), with the following address:
/movie.php?id=20§ion=bts&w=480&h=360
In this frame, the actual movie is embedded - the first bookmark to list embedded media worked great.
Get a list of links of the files which I downloaded.
* This may work in Safari for Mac only, other Platforms are not yet tested.
Continue reading "save any quicktime video from websites" »