Panther’s Address Book: Can’t easily copy home page URLs in Browse mode
Posted by Pierre Igot in: MacintoshJuly 8th, 2004 • 3:57 am
One day, BBEdit will support Spell Catcher X‘s interactive completion feature and let me automatically insert home page URLs from my Address Book entries by typing the first few letters of the person’s or company’s name and hitting F5…
Until then, however, I am still forced to do a lot of cutting and pasting when I want to enhance the name of a person that I quote in my blog by turning that name into a live link to their home page.
To make matters worse, however, there is a strange limitation in Panther’s Address Book when you browse address book entries and try to retrieve the contents of the “home page” field:
As you can see in this picture, the “home page” field does have a contextual menu that includes the “Copy” command — but that command is disabled, even when the field does contain something!
The only way to copy the home page URL from an Address Book card is to painstakingly click and drag somewhere around the beginning (or the end) of the URL itself in order to select it — and hope you haven’t selected anything else at the same time.
I really have no idea why the “
” command doesn’t work here!
July 8th, 2004 at Jul 08, 04 | 4:25 am
I assume the copy command exists there because the whole address book record is some strange kind of text-field like contraption. Yet you haven’t selected any text.
AppleScript is your friend here: Try this
and then paste wherever you want. You could use an application’s script menu for this or LaunchBar.
In fact, if you are using LaunchBar, it’d be even easier to navigate to the contact in question and simply hit command-C when its web page is selected :)
The script above could also be easily converted into an address book plugin to be run from the contextual menu for the home page entry, btw.
July 8th, 2004 at Jul 08, 04 | 4:30 am
I blame the stupid authors of your blogging software for not taking care that my script is published unharmed. (Even though it was in their silly alteration of a pre-tag)
I didn’t enter any curly quotes and the second to last line should read: (fingers crossed this time)
set myLink to "<a href="" & theURL & "">" & theName & "</a>"
July 8th, 2004 at Jul 08, 04 | 4:47 am
Yeah, sorry about the limitations of the blogging software, I guess it doesn’t like double quotation marks. They all have their idiosyncratic behaviours :-/. (I could turn the auto-formatting for comments, but I am not sure it would solve the problem.)
I ended up modifying your script somewhat, because I don’t want the extra HTML code, I just want the URL (which solves the problem with the escaped quotation marks :)). So here it is:
Also, you must be using a beta version of LaunchBar 4, because LaunchBar 3.x doesn’t let you access a person’s Address Book card. It only lets you create a new e-mail with that person’s address.
Anyway, I ended up saving the script as an Address Book script with Script Editor with the following name:
Then I went to System Preferences’ Keyboard Shortcuts pane and created a keyboard shortcut (ctrl-C) for this particular menu item in Address Book’s Scripts menu. And it works just fine :).
Thanks a bunch.
July 8th, 2004 at Jul 08, 04 | 4:54 am
I still feel that this default behaviour in Address Book’s Browse mode is somewhat problematic.
There are in fact several problems. One is that the contextual menu that you get when clicking on a field label is different from the contextual menu you get when control-clicking on a field label. So presumably the additional commands in the ctrl-click contextual menus apply to the card as a whole rather than to that particular field, hence the problem with what’s selected or not.
There is no visual indication of this, however.
Interestingly, the contextual menu for the mailing address field has a command called “Copy mailing label”, which is effectively a “Copy” command that’s specific to the mailing address field.
July 8th, 2004 at Jul 08, 04 | 5:00 am
Note that clicking on the labels on the address card is not a contextual menu click.
(As they should) Apple made sure these menus are accessible to all (i.e. wihtout having to use extra mouse buttons or keys). While their choice for UI may be questionable, it’s not too far off what they do for the bookmark bar in Safari.
The mailing address field only has that item in its _contextual_ menu because it is in its label menu as well.
July 8th, 2004 at Jul 08, 04 | 5:03 am
BTW, I can wholeheartedly recommend the betas of LB4 ? they got me to actually buy the program. Not only do you have your whole address book and music library at your finger tips, you can also pass parameters to items and start google or imdb or (yourfavouritesitehere) searches right from LaunchBar.
You should give it a try.
July 8th, 2004 at Jul 08, 04 | 6:16 am
I am a heavy LaunchBar 3 user. I was just waiting for LB4 to come out of the beta stage. But I guess it must be pretty mature by now.
And yes, I do think that the UI in Address Book is questionable :).
July 9th, 2004 at Jul 09, 04 | 11:20 pm
For the record, I’ve reported the problem with curly quotes in code to pMachine and they are going to fix it:
http://www.pmachine.com/forum/threads.php?id=19051_0_4_0_C