Address Book Plugin for European maps via Michelin
Since I read on macOSXHints
that everyone in the USA is shopping for teletubbie dolls today, it’s a good time to post things with a more international flavour.
Annard Brouwer has written an Address Book plugin that provides look-ups for European addresses through the ViaMichelin
map service.
They may well be more accurate than other mapping services and come with pretty scaled images of significant landmarks:

Installation is easy. Download the script from Annard’s web site
and place the plugin in your ~/Library/Address Book Plug-Ins folder.
Restart Address Book and you will see a “Via Michelin map of …” option in the contextual menu that appear when you click on the label of a European address.
Other plugins exist which do something similar for European addresses and you can find them in the Address Book section of this site’s plugin list.
[Thanks, Annard]
Tags: Address Book, contacts, Europe, maps, MichelinRelated posts

November 25th, 2006 at 12:50 am
Hmm, doesn’t work here (for Germany). I experimented a little with with how the country was entered (English vs. German), but the map service always shows a blank map.
November 25th, 2006 at 1:07 am
Odd. It works fine for me with German addresses, pulling up one correctly in Berlin first time.
I have “Germany” entered as the country.
November 25th, 2006 at 2:07 am
Yes, the script is a bit tricky with the names of the countries. It expects them to be fully spelled out in English. The source is available on request so you can mess with it. Just send me an email.
November 25th, 2006 at 11:15 pm
The google maps pulg-in also works for international addresses.
November 26th, 2006 at 3:18 am
- “Tricky” quite catches the point. It will not accept “England” for example, but only “United Kingdom”.
- viamichelin only works with cookies active, too bad
November 26th, 2006 at 9:25 am
I got several requests for localisation but I knew that AddressBook has the ISO2 country codes. So I changed my code to take advantage of this and thus it is now independent on how you describe the country. BUT you will need to set the address format to the correct country in order for this to work.
Cheers!
Annard
November 27th, 2006 at 2:10 pm
How do you “set the address format to the correct country” on individual cards? This setting is in the preferences, and seems to apply on a global level. How can I have my German addresses use a German format and my American addresses keep their American format?
November 27th, 2006 at 8:36 pm
That’s very easy: when you edit a card and click on the label of a postal address you can select “Change Address Format >” and then select the correct country from the list.
November 28th, 2006 at 2:17 am
Ive done the change of address format but the viaMichelin is there but not enabled. Do you need to be a member of michelin for this?
November 28th, 2006 at 12:25 pm
The script doesn’t work with german umlauts (äöüßÄÖÜ), they need to be translated to their ISO latin 1 encodings.
Just try my address: Görlitzer Straße 11, 41460 Neuss, Germany
So I added a little function that does the required translation, may be more translations are needed for other languages.
on urlencode(theText)
– äöüßÄÖÜ => %E4%F6%FC%DF%C4%D6%DC
set the charToEncode to ” äöüßÄÖÜ”
set theTextEnc to “”
considering case
repeat with eachChar in characters of theText
set the ACSII_number to (the ASCII number eachChar)
if eachChar is in “äöüßÄÖÜ ” then
if ACSII_number = 32 then
set theTextEnc to theTextEnc & “+” as string
end if
if eachChar = “ä” then
set theTextEnc to theTextEnc & “%E4″ as string
end if
if eachChar is in “ö” then
set theTextEnc to theTextEnc & “%F6″ as string
end if
if eachChar is in “ü” then
set theTextEnc to theTextEnc & “%FC” as string
end if
if eachChar is in “ß” then
set theTextEnc to theTextEnc & “%DF” as string
end if
if eachChar is in “Ä” then
set theTextEnc to theTextEnc & “%C4″ as string
end if
if eachChar is in “Ö” then
set theTextEnc to theTextEnc & “%D6″ as string
end if
if eachChar is in “Ü” then
set theTextEnc to theTextEnc & “%DC” as string
end if
else
set theTextEnc to theTextEnc & eachChar as string
end if
end repeat
end considering
return theTextEnc
end urlencode
And then
set params to urlencode(params) as string
– this is all it takes to make the jump itself
tell application “System Events” to open location ViaMichelinURL & params
November 28th, 2006 at 7:51 pm
To Warren: Via Michelin doesn’t work all over the world, so if the country of the address is not in a supported country, it will be disabled.
To Helge: I did try it with an address with an ü in it and it worked. I assumed that Via Michelin supports UTF-8 encoded URLs (since that’s the official W3C take on it). The source is now included and since it’s free you can do with it what you like.
May 11th, 2007 at 7:11 am
Works great.
I have translated it in French, and published on my blog:
http://sd55.free.fr/wordpress/?p=16