Suggestion: Webmail as preferred mail application

Asked by Willi

In Ubuntu's Preferred applications app, you can choose which installed mail reader to use. This is the application that will launch when a mailto: link is clicked.
However, a lot of (most?) people prefer webmail over Evolution or Thunderbird.
It is not at all clear to the average user how to set this up, which is why I think this would make a great addition to Ubuntu Tweak.

Tweak could have a dropdown list containing the usual installed mail applications but with webmail clients (Gmail, Hotmail, Yahoo! Mail, AOL Mail) added to the list.

It would then have to change the following key in gconf: /apps/desktop/gnome/url-handlers/mailto/command to: /path/to/script/mailto.sh "%s"
while changing /apps/desktop/gnome/url-handlers/mailto/enabled to true and /apps/desktop/gnome/url-handlers/mailto/needs_terminal to false.

The scripts are the following:

Gmail:
#!/bin/bash
xdg-open "https://mail.google.com/mail?view=cm&tf=0&to=`echo "$1" | sed -e 's/mailto:\([^?]*\).*/\1/'`"

Hotmail:
#!/bin/bash
xdg-open "http://www.hotmail.msn.com/secure/start?action=compose&to=`echo "$1" | sed -e 's/mailto:\([^?]*\).*/\1/'`"

Yahoo! Mail:
#!/bin/bash
xdg-open "http://compose.mail.yahoo.com/?To=`echo "$1" | sed -e 's/mailto:\([^?]*\).*/\1/'`"

AOL Mail:
#!/bin/bash
xdg-open "http://webmail.aol.com/25045/aol/en-us/Mail/compose-message.aspx?to=`echo "$1" | sed -e 's/mailto:\([^?]*\).*/\1/'`"

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Tweak Edit question
Assignee:
No assignee Edit question
Solved by:
Ding Zhou
Solved:
Last query:
Last reply:
Revision history for this message
Best Ding Zhou (tualatrix) said :
#1

Great!
Thanks for you suggestion!
I will try to implement this idea.

Revision history for this message
Willi (strangeq) said :
#2

Thanks TualatriX, that solved my question.

Revision history for this message
Oleg Yermakov (epushiron) said :
#3

Maybe this program solves the problem better:

http://www.ubuntugeek.com/access-gmail-hotmail-yahoo-and-zoho-webmail-from-your-ubuntu-desktop.html

«Webmail for Linux Desktops provides a generic mailto: handler and webmail config dialog that lets the user choose his preferred webmail provider on first run and through the desktops Preferences->Webmail facility.
When clicking on mailto: links on your desktop or in your browser desktop-webmail will take care that the user gets redirected to his webmail of choice’s compose webpage with the proper fields pre-filled in.

Currently default webmail providers are: Gmail, Hotmail, Yahoo and Zoho.

Currently this is available for ubuntu lucid»