GMailTo by N-Dream

By N-Dream Last update Sep 28, 2006 — Installed 22,358 times.

Archived Comments (locked)

Subscribe to Archived Comments 10 posts, 10 voices

Jesse Andrews Admin

The following is an archive of comments made before threaded discussions was implemented (November 16th, 2008)

Julien Couvreur Scriptwright

For those interested:
Here is the original "Mailto Compose in GMail" (which was feature in the Greasemonkey Hacks book and handles all the mailto: url formats):

jacotyco User

could you make it so it opens in a new tab?

Mike Cunneen User

Here is a hacked source to open a gmail compose window, as requested. YMMV.

// ==UserScript==
// @name GMailTo
// @namespace
// @description Forces all mailto links to open in GMail
// @include *
// ==/UserScript==

//Super fast recursive lookup if it is a mailto: link
function goUp(target,howmany) {
if(howmany>0) {
if(target.nodeName=="A") {
if(target.href.indexOf("mailto:")==0) {
if((strip=mail.indexOf("?"))!=-1) {
if((strip=mail.indexOf("&"))!=-1) {
var mailwin =""+mail+"&cc=&su=&body=&fs=1","mailwin","menubar=no,toolbar=no,location=no,directories=no,personalbar=no,status=no,dependent=yes,width=640,height=480");
target.href = null; = null;
return false;
} else {
} else {
if(target.parentNode!=null) {
} else {
} else {

window.addEventListener("click",function(e) {
if(e.which==1) {
}, false);

sleijer User

Nice little script.

Could someone tweak the script so that clicking a mailto-link would pop up a Gmail compose window, which closes automatically after you have sent the e-mail. My javascript skills are non-existent :).

cobra75007 User

Super script !!!

Jake McGraw User

This is okay, but this is much better (full support for 'mailto' urls):

Ferenc Gerlits Scriptwright

Great little script, thank you!

N-Dream Script's Author

Ofcourse it does! LOL

Rafael User

it works