MapIt Plugin - Bringing Maps to Email & Contacts

May 31, 2010

We’ve just release the initial version of our MapIt plugin for Atmail. This handy little plugin provides mapping to both the email and contacts portions of Atmail. First up all email bodies are scanned looking for anything that resembles a street address, when found the plugin can utilizes Google or Yahoo maps to create a map for the address then makes the address text interactive by popping up the map when the address is hovered over. If you click the address “link” then the map becomes sticky and stays visible till you click again, cool huh? The plugin underlines the address to give the user the idea that it can be hovered and/or clicked:

For contacts the plugin searches for any Home Address or Work Address information, if found it again uses Google or Yahoo maps to place a static map of that address on the page below the relevant address information:

Once installed via Atmail’s Webadmin you can edit the configuration file found at /path/to/atmail/webmail/config/plugins/mail.atmail.mapit.ini to alter behavior. Below is a sample configuration file:

[main]

# Mapping service to use ‘google’ or ‘yahoo’
map.service = google

# Map size, only relevant for map displayed on viewing a contact
map.size = 300×300

# Show a map upon viewing a contact if there are sufficient address details
option.process_contact = On

# Process email body contents and look for addresses to fetch a map for
option.process_email_body = On

You can download MapIt from here. We hope you find this little plugin useful!


Filed under: Frontpage — Brad Kowalczyk @ 12:56 am

5 Comments »

  1. Nice plugin! It works great for the addressbook, but I cannot get it to work very well for text embedded in emails.

    It failed to recognize any of these attempts:

    5744 Industry Ln. Frederick

    5744 Industry Ln. Frederick, MD

    5744 Industry Ln. Frederick Maryland

    5744 Industry Ln. Frederick, MD 21703

    5744 Industry Ln. Frederick 21703

    5744 Industry Ln. 21703

    However, it did successfully recognize the string you used above, “55 Second Ave New York”…however that had an issue as well: in 2-pane view (which we prefer to the 3-pane view), the popup box always displays to the left of the text, preventing me from seeing the map as it’s “hidden” by the folder pane.

    In 3-pane view the popup box is properly displayed to the right of the link as in your example above.

    This is with IE 8, what most of our customer base uses.

    So, needs a little work, but excellent idea!

    Comment by Andy Dills — May 31, 2010 @ 7:55 am
  2. Thanks for the feedback Andy! I’ll test using the 2-pane view today and try to sort out the issue. I’ll also work on the regex that searches for addresses in emails. As you can imagine this first version uses a less flexible pattern, we’ll improve on it as we go. I’ll post updates here.

    Cheers,

    Brad

    Comment by Brad — May 31, 2010 @ 5:21 pm
  3. Hi Andy, it’s the period after the Ln that’s messing it up. I’m working on an improved algorithm that supports this and also is more flexible so as to match all of your examples and others. Look out for it in the next version of MapIt.

    Comment by Brad — May 31, 2010 @ 11:14 pm
  4. Could you please generally write down the requirement like php extensions and so on!

    Thanks a lot, and you guys do a awesome job!!!

    Comment by Jan — September 15, 2010 @ 1:34 pm
  5. Hi Jan,

    There should be no extra dependencies for this plugin to work. Are you experiencing problems?

    Cheers,

    Brad

    Comment by Brad — September 19, 2010 @ 11:59 pm

RSS feed for comments on this post. TrackBack URI

Leave a comment