¶ Bookmarklet To Download YouTube Videos As MP4s
Monday, April 14, 2008, 7:09pm
An interesting side-effect of YouTube's recent push for higher quality videos is that most videos can be downloaded as MP4 files directly from YouTube. Until now, you could only get FLV files from your browser's cache or using one of the many websites that let you download YouTube videos. In fact, to download the MP4 files, you need to use the same URL like for FLV files and append "&fmt=18":
http://www.youtube.com/get_video?video_id=ID&t=SIGNATURE&fmt=18
ID is the video's identification value, SIGNATURE is a value that prevents you from downloading the file just by knowing the ID. You could create this URL by looking at the source code of a YouTube page, but it's much easier to automatically generate it.
Curly Quotes To Straight Quotes Meets Blog This Bookmarklet For Drupal
Saturday, January 12, 2008, 12:37pm
Using Drupal's prepopulate module, bookmarklets, like the one bundled with WordPress, to blog this are easy to craft. (Though at the time, it wasn't properly documented how to form prepopulated URIs when using grouped CCK fields.)
Anyhow, leaning heavily on Mark Pilgrim's Dumb Quotes code (found via a del.icio.us Dumbify Quote Bookmarklet), I came up with the following:
javascript: u=location.href; t=document.title; s=""+(window.getSelection?window.getSelection():document.getSelection?document.getSelection():document.selection.createRange().text); s=s.replace(/\"/g,"'"); s=s.replace(/\xa0/g,""); s=s.replace(/\xa9/g,"\(c\)"); s=s.replace(/\xae/g,"\(r\)"); s=s.replace(/\xb7/g,"*"); s=s.replace(/\u2018/g,"'"); s=s.replace(/\u2019/g,"'"); s=s.replace(/\u201c/g,'"'); s=s.replace(/\u201d/g,'"'); s=s.replace(/\u8220/g,"'"); s=s.replace(/\u8221/g,"'"); s=s.replace(/\u2026/g,"..."); s=s.replace(/\u2002/g,""); s=s.replace(/\u2003/g,""); s=s.replace(/\u2009/g,""); s=s.replace(/\u2012/g,"--"); s=s.replace(/\u2013/g,"--"); s=s.replace(/\u2014/g,"--"); s=s.replace(/\u2015/g,"--"); s=s.replace(/\u2122/g,"\(tm\)"); void(window.open(%22http://brianpuccio.net/node/add/excerpt?edit[group_external_content][field_external_title][0][value]=%22+encodeURIComponent(t)+'&edit[group_external_content][field_external_content][0][value]='+encodeURIComponent(s)+'&edit[group_external_content][field_external_link][0][value]='+encodeURIComponent(u),'_blank','width=1024,height=500,status=yes,location=yes,resizable=yes,scrollbars=yes'));
Modify as needed for your personal site.
Javascript Bookmarklet To Generate Link Tag To Current Page With Title Attribute
Wednesday, August 8, 2007, 7:09am
javascript:var url=document.location; var title=document.title; var link='<a href="' + url + '" title="' + title + '"></a>'; alert(link);
Javascript Bookmarklet For Generating Link To Current Page With Title Attribute
Sunday, March 25, 2007, 9:21pm
I wrote a small JavaScript bookmarklet to generate the HTML code for a link to the current page open in a browser, including the page's title attribute.
javascript:var url=document.location; var title=document.title; var link='<a href="' + url + '" title="' + title + '"></a>'; alert(link);