O'Reilly logo

Greasemonkey Hacks by Mark Pilgrim

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 7. Web Mail

Hacks 60–66: Introduction

One of the most popular uses for the Internet in the early 1990s was email. Personal email, email-based newsletters, and email-based discussion groups all drove people onto the Internet. It was the killer app: the one feature people couldn’t live without.

Then the Web exploded onto the scene, and pundits and self-proclaimed experts declared that the killer app of the Web was interactive TV. And then it was search. And then it was shopping. And then it was interactive TV again. (Somewhere in there was that whole 3D VRML craze that lasted about five minutes. Boy, that was fun…not.)

And here we are, in the year 2005. What’s the killer app of the Web? What’s the most impressive, most fantastic, most mind-bogglingly useful thing to hit the Web in the past 10 years? Gmail, a web-based email service. God, I love the Internet.

Force Gmail to Use a Secure Connection

Protect your inbox by automatically redirecting Gmail to an https:// address.

You can use Google’s web mail service through an unsecured connection (an http:// address) or a secure connection (an https:// address). When I’m out and about and browsing the Web on an untrusted network (such as an Internet cafe), I try to remember to use the https:// address. But why bother remembering, when Greasemonkey can remember it for me?

The Code

This user script is literally one line of code. The reason it can be so small is that we configure it to run only on http://mail.google.com, the insecure address ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required