Apr 29, '05 09:01:00PM • Contributed by: Hes Nikke
Mapquest is an aging mapping system and doesn't fit in with the new shinyness in Tiger. Thats why I made the phone book widget use Google Maps instead.
- In the Finder, go to /Library/Widgets
- Control-click on Phone Book.wdgt, and choose Show Package Contents from the pop-up menu
- Duplicate PhoneBook.js so that you have a back up -- just in case.
- Open PhoneBook.js in your favorite Text Editor (I used BBEdit).
- Find the following block, which begins on line 802:
var mapURL = "http://www.mapquest.com/maps/map.adp?country=us&address="; mapURL += URLEncode( singleResult.address ); mapURL += "&city="; mapURL += URLEncode( singleResult.city ); mapURL += "&state="; mapURL += URLEncode( singleResult.state ); mapURL += "&zip="; mapURL += URLEncode( singleResult.zip ); - Replace that block with the following block:
var mapURL = "http://maps.google.com/maps?q="; mapURL += URLEncode( singleResult.address ); mapURL += "+"; mapURL += URLEncode( singleResult.zip ); mapURL += "&hl=en"; - Save changes to the file and quit the editor.
[robg adds: I received a similar hint submission from Anonymous, and the only difference was their code for the replacement section. Their code was:
var mapURL = "http://maps.google.com/maps?q=";
mapURL += URLEncode( singleResult.address );
mapURL += "+";
mapURL += URLEncode( singleResult.city );
mapURL += "+";
mapURL += URLEncode( singleResult.state );
mapURL += "+";
mapURL += URLEncode( singleResult.zip );
Since I don't have Tiger with me on the road, I can't test either version right now -- so take your pick, and use the one that works the best!]
