<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Zomgee&#187; Tech</title>
	<atom:link href="http://zomgee.com/tag/tech/feed/" rel="self" type="application/rss+xml" />
	<link>http://zomgee.com</link>
	<description>lawl</description>
	<lastBuildDate>Fri, 23 Apr 2010 17:34:24 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Mailto Links and Zimbra [How to]</title>
		<link>http://zomgee.com/2009/07/20/mailto-links-and-zimbra/</link>
		<comments>http://zomgee.com/2009/07/20/mailto-links-and-zimbra/#comments</comments>
		<pubDate>Mon, 20 Jul 2009 20:58:30 +0000</pubDate>
		<dc:creator>Dan</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[Tech]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[mailto]]></category>
		<category><![CDATA[zimbra]]></category>

		<guid isPermaLink="false">http://zomgee.com/?p=678</guid>
		<description><![CDATA[<div class="postavatar"><img class=" av" src="http://zomgee.com/wp-content/uploads/icons/dan.png" width="80" height="80" alt="mailto-links-and-zimbra-how-to" /></div>
I&#8217;ve been looking throughout the Internet today looking for ways to get mailto: links to work with Firefox and Zimbra. Since I didn&#8217;t want to touch the registry and most of the people here use Macs anyway, I had to make a Greasemonkey script to do the job. Sure, there are already scripts to do [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img class=" av" src="http://zomgee.com/wp-content/uploads/icons/dan.png" width="80" height="80" alt="mailto-links-and-zimbra-how-to" /></div>
<p>I&#8217;ve been looking throughout the Internet today looking for ways to get mailto: links to work with Firefox and Zimbra. Since I didn&#8217;t want to touch the registry and most of the people here use Macs anyway, I had to make a Greasemonkey script to do the job. Sure, there are already scripts to do this, but they point to the standard interface. I wanted the advanced interface.</p>
<p><span id="more-678"></span>First, take this code, put it in a text editor, and change &#8220;mail.server.com&#8221; to your zimbra server (2 instances).</p>
<p><code><br />
// ==UserScript==<br />
// @name            Mailto Compose In Zimbra<br />
// @namespace       http://www.dawnbreaker.com<br />
// @description     Rewrites "mailto:" links to Zimbra compose links<br />
// @include         *<br />
// @exclude         https://mail.server.com<br />
// ==/UserScript==<br />
(function() {<br />
var processMailtoLinks = function() {<br />
var xpath = "//a[starts-with(@href,'mailto:')]";<br />
var res = document.evaluate(xpath, document, null,<br />
XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null);<br />
var linkIndex, mailtoLink;<br />
for (linkIndex = 0; linkIndex &lt; res.snapshotLength; linkIndex++) {<br />
mailtoLink = res.snapshotItem(linkIndex);<br />
//alert(mailtoLink.href);<br />
var m = mailtoLink.href;<br />
var matches = m.match(/^mailto:([^\?]+)(\?([^?]*))?/);<br />
var emailTo, params, emailCC, emailSubject, emailBody;<br />
emailTo = matches[1];<br />
//alert("Found to=" + emailTo);<br />
params = matches[3];<br />
if (params) {<br />
var splitQS = params.split('&amp;');<br />
var paramIndex, param;<br />
for (paramIndex = 0; paramIndex &lt; splitQS.length; paramIndex++) {<br />
param = splitQS[paramIndex];<br />
nameValue = param.match(/([^=]+)=(.*)/);<br />
if (nameValue &amp;&amp; nameValue.length == 3) {<br />
// depending on name, store value in a pre-defined location<br />
switch(nameValue[1]) {<br />
case "to":<br />
emailTo = emailTo + "%2C%20" + nameValue[2];<br />
break;<br />
case "cc":<br />
emailCC = nameValue[2];<br />
//alert("Found CC=" + emailCC);<br />
break;<br />
case "subject":<br />
emailSubject = nameValue[2];<br />
//alert("Found subject=" + emailSubject);<br />
break;<br />
case "body":<br />
emailBody = nameValue[2];<br />
//alert("Found body=" + emailBody);<br />
break;<br />
}<br />
}<br />
}<br />
}<br />
mailtoLink.href = "https://mail.server.com/zimbra?app=mail&amp;view=compose" +<br />
(emailTo ? ("&amp;to=" + emailTo) : "") +<br />
(emailCC ? ("&amp;cc=" + emailCC) : "") +<br />
(emailSubject ? ("&amp;subject=" + emailSubject) : "") +<br />
(emailBody ? ("&amp;body=" + emailBody) : "");<br />
// mailtoLink.onclick = function() { location.href = newUrl; return false; };<br />
}<br />
}<br />
window.addEventListener("load", processMailtoLinks, false);<br />
})();<br />
</code><br />
Then paste the code into the generator here: <a href="http://arantius.com/misc/greasemonkey/script-compiler" target="_blank">http://arantius.com/misc/greasemonkey/script-compiler</a></p>
<p>Leave the GUID as it is, change the max version to 3.5.* and then add anything else you might want.</p>
<p>Compile the script and then install the .xpi file into firefox.</p>
<p><map name='google_ad_map_678_c7b6f2e76a490627'>
<area shape='rect' href='http://imageads.googleadservices.com/pagead/imgclick/678?pos=0' coords='1,2,367,28' />
<area shape='rect' href='http://services.google.com/feedback/abg' coords='384,10,453,23'/></map>
<img usemap='#google_ad_map_678_c7b6f2e76a490627' border='0' src='http://imageads.googleadservices.com/pagead/ads?format=468x30_aff_img&amp;client=&amp;channel=&amp;output=png&amp;cuid=678&amp;url= http%3A%2F%2Fzomgee.com%2F2009%2F07%2F20%2Fmailto-links-and-zimbra%2F' /></p>]]></content:encoded>
			<wfw:commentRss>http://zomgee.com/2009/07/20/mailto-links-and-zimbra/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
	</channel>
</rss>
