Any way to send an e-mail from a GM Script?

1,868 views
Skip to first unread message

Tibby

unread,
Feb 15, 2011, 3:38:16 PM2/15/11
to greasemonkey-users
Hi All,

I am new here, and am relatively new to GM, so was wondering if I
could draw on others experience?

Does anyone happen to know if it is possible to send an e-mail from a
GM script?
Or if failing that any way I could send a notification to a phone (the
idea being that a script watch a site, and then upon a trigger in the
code being hit, it would e-mail an account that has instant push on
the iPhone)

Google has come up short on this one, so hopefully someone here has
some experience.

I am mainly a Java EE coder, and deal with Back-End stuff so my first
instinct is to setup an SMTP server on the system and have it interact
via that, but I'm not sure if that would be out of the scope of GM as
I assume it can only interact with the pages in question?

Thanks for any help!

Anthony Lieuallen

unread,
Feb 15, 2011, 3:48:51 PM2/15/11
to greasemon...@googlegroups.com
On 02/15/11 15:38, Tibby wrote:
> Does anyone happen to know if it is possible to send an e-mail from a
> GM script?

No. You can call, via HTTP, to a site. If you can set up a site to
send that email, then you've got a path to completion.

Tibby

unread,
Feb 15, 2011, 4:18:19 PM2/15/11
to greasemonkey-users
Hmm would it be possible to open a pop-up which would autopopulate my
gmail details for me, and send an e-mail?

esquifit

unread,
Feb 15, 2011, 5:48:15 PM2/15/11
to greasemon...@googlegroups.com
On Tue, Feb 15, 2011 at 9:38 PM, Tibby <tiber...@gmail.com> wrote:

> Does anyone happen to know if it is possible to send an e-mail from a
> GM script?
> Or if failing that any way I could send a notification to a phone (the
> idea being that a script watch a site, and then upon a trigger in the
> code being hit, it would e-mail an account that has instant push on
> the iPhone)

If I were you I'd try a combination of screen scrapping (via JGate for
example) plus Tarpipe for the e-mail notification. (JGate offers
hosting of server-side javascript). Just an idea.

sizzlemctwizzle

unread,
Feb 15, 2011, 6:11:32 PM2/15/11
to greasemonkey-users
You could send email pretty easily with GM and Gmail. Just use the
mobile version of Gmail(m.gmail.com) to make script writing simpler.
Although, I don't think GM is the best tool for this job. You'd need
your browser open for this to even work.

Tibby

unread,
Feb 16, 2011, 4:47:45 AM2/16/11
to greasemonkey-users
Thanks for all your ideas guys. I've got some downtime at work while
waiting for server tests to finish up, so will get researching!

RodMcguire

unread,
Feb 16, 2011, 8:37:28 AM2/16/11
to greasemon...@googlegroups.com
"would it be possible to open a pop-up which would autopopulate my
gmail details for me, and send an e-mail?"

Script 1:

1) Take the info you want to send and encode it into a hash tag. See:

    http://wiki.greasespot.net/Controlling_userscripts_in_sub_windows

Lets say you use an online e-mail program at foomail.com.

2) Open a window to http://foomail.com/XXX#(encoded mail info)

Script 2:

1) Write a GM script for foomail.com that
 a) decodes the hash passed email info
 b), populates a send mail page
 c)  automatically sends it.
 d) closes itself


Reply all
Reply to author
Forward
0 new messages