cyborgzombieninjapirate


Gmail as Default Mail Client in Ubuntu ala PHP.

Posted on 18.07.2009 01:00 pm

After reading this article (Set Gmail as Default Mail Client in Ubuntu). I felt compelled to update the script he was using.

I chose to use PHP because it has a great and simple to use url parser to handle the extra arguments.

The script I wrote can be found here as a .phps file. Just rename it to .php and replace it with the .sh file in the article above.

It supports all the extra mailto: arguments like subject, cc, bcc and body. You can try it out here. (MailTo Synax)

There is one caveat. If any of the arguments contain unsafe characters for a shell, then they will be escaped with a backslash.

I haven't tested it out on Windows. If you have I'd love to hear about it. Also if you rewrite it in other languages I'd love to hear about it also.

0 2    Like it or hate it?  -  Comment (0)


(Used for gravatar only, never displayed)

What is 2 + 5


Memory allocated for your request: 180.61 Kb
Process time: 0.011314 seconds