I described in an older article how to make a webmail service, in this case Gmail, your default email client in several browsers. With the release of Opera 11.60 at the end of December, setting this up got slightly more user-friendly. Opera now supports custom protocol and content handlers, meaning that adding Gmail as the default protocol handler can be done directly in the browser, following these steps:
- Login to your Gmail account in Opera;
- Type the following command in the address bar and press Enter:
javascript:window.navigator.registerProtocolHandler("mailto","https://mail.google.com/mail/?extsrc=mailto&url=%s","Gmail")
- Confirm at the prompt and you’re done!
The next time you click on a mail-link (you can try it out at this test page) you will see another prompt to choose your default application for mailing and Gmail should now be one of the options. If you change your mind later, the setting can be changed from the Opera Preferences, on the Advanced tab under Programs.
In theory, this method should also work in Google Chrome, since it also supports registering web services as protocol handlers. The procedure above seems to work without error, however when I actually click on a mailto:-link, the browser throws up an error: ‘This webpage is not available’. My guess is that the protocol for mailto: is not yet fully implemented in Chrome, otherwise this wouldn’t work in other browsers.
Update: After a couple of weeks, the tip above started working in Chrome as well; it’s probably one of the final tweaks applied before releasing the stable version 17.
Getting Gmail to handle all mailto: links with registerProtocolHandler() updates.html5rocks.com/2012/02/Gettin…
— Chrome Dev Relations (@ChromiumDev) February 8, 2012
19 comments:
Many thanks! We have tried to accomplish this for year! Bravo!!
I'm on 11.60, and I don't get any kind of confirmatory prompt. The command seems to have no effect at all. Help
Hi!
The code above only works if you run it from the address bar of a tab where Gmail is loaded, from any other tab it will have no effect.
Otherwise you should check the advanced settings in opera:config for an entry called Disallowed Web Handlers that can prevent websites to register themselves as handlers for webapps. Reset the setting, because the default is 'allow' and it should work.
Finally! :-) But still, why it is so cumbersome... ;-)
I have version 11.60 as well and am having the same difficulty (no confirmatory prompt). I checked the Disallowed Web Handlers and made sure it was set to default but to no avail :(
Hmm, I don't know what to say in that case... it could be some sort of bug.
Have you checked if Gmail is listed as a handler under Options > Advanced > Programs?
Another thing I noticed on the change log page for Opera 11.60 is that they changed the UI related to handlers: "Web handler toolbar not invoked for mailto protocol after another protocol handler has been deleted". Maybe you accidentally deleted another handler and now the dialog won't show... Weird design choice if you ask me!
I just checked and the protocol mailto: is listed under Advanced > Programs. Although it doesn't say "Gmail". If I try and edit it I have these options:
Open with Opera
Open with Webmail service > (the ones that ship with Opera)
Open with Default application> .exe" "C:\Windows\system32\url.dll", MailToProtocolHandler%.... (I can't see more as it's an uneditable field
Open with Other Application > javascript:window.navigator.registerProtocolHandler( mailto , https://mail.google.com/mail/?extsrc=mailto&url=%s , Gmail )
While it is possible that I've deleted another protocol handler, I try not to mess with things too much as a rule. If that's the case though, I have to agree that is a weird design choice!
That's not right, by me 'Gmail' is listed under Use a Webmail service alongside the default options. Try to delete the text from Open with Other Application, set the option back to Open with Opera and try the tip again. If that still doesn't work, there is still my older tip, which involves manually modifying an Opera config file, you can find it here.
Thanks :)... but still nothing. I tried your older tip as well, but it won't let me modify the file at all. I can open it, by but it says "access denied" if I try and save it. Any suggestions?
NVM! I could edit it in safe mode. The job is done. Thanks for the tips!
Ah, yes, I remember having problems with modifying that file as well on Windows 7. I don't know if I mentioned it in the original post, but I got around the limitation by copying the file in another locations, making the changes there and then replacing it in the original folder. There was a warning as well, but I could bypass it by logging in as admin. I'm glad you got it to work!
This didn't work for me. I completed steps 1-3 and in Advanced options it is set to "Gmail" under "Use a Webmail", but I never got another prompt to choose my default application for mailing. In fact, nothing at all happens when I click mailto links.
Other than the troubleshooting ideas we already discussed in the previous comments, I'm afraid I don't have any other suggestions...
Since you now see "Gmail" under "Use a Webmail service" and it's already selected, you shouldn't see any other prompts. Have you tried to change the setting (to 'Open in default application' for example) and check if the mailto:-links work in that case?
Is there way to open the new message in full Gmail interface (with sidebars etc.) as with the previous method?
If there is, I'm not aware of it. It's probably hard-coded into the internal code in Gmail used to handle the mailto: protocol.
Excellent, a nice time-saver. Thank you!
Thank you, it's working!
Thank you! Worked like a charm.
Thank you! Worked like a charm. :-)
Post a Comment