Current Page |
|
Submitted By James Sinclair (megalogeek) |
DescriptionAdds link insertions support like %_safari for Camino, Firefox, Mozilla and Netscape users.Since none of these browsers support Applescript, these scritps are pretty much hacks, but the Firefox, Mozilla and Netscape scritps are ugly hacks. I tried all sorts of ways to get the URL from these browsers, but the only one that worked requires bringing the browser to the front for two seconds. It's ugly, but it works. If you can't live with that, sorry. The script does it all for you, but it's mildly annoying to have the browser pop forward for 2 seconds then go away again. Oh well. Mozilla and Netscape both tag their own name onto the title of the browser window, so unfortunately, that'll show up in the link text. FYI -> I'm working on Opera support, but it seems to be horribly Applescript impaired. I'll post a new version if I can get it working. CommentsYou can reply to individual comments by clicking the "Reply" link next to each. # by Anonymous on 10/23/04 at 07:34:13Even considering the v6+ versions of Netscape are just rebranded releases of Mozilla?
# by megalogeek on 10/23/04 at 20:59:21I update it to v1.1 - This adds support for Mozilla & Netscape. Unfortunately, Opera support is not looking very likely at the moment. I might be able to get just the URL, but I can't seem to get the page title. Still, just a url is better than nothing.
I'm working on addimg more browsers too. OmniWeb and iCab look pretty easy because they are Applescriptable. Of course, it has occurred to me that not everyone will want to install all the scripts, so the next release will probably have extra .adiumscripts to install them individually. I'm also looking at making a meta-script that will figure out which browser you have running and just use it (or give you a select list if there's more than one). That might take a little longer. Hope you enjoy it. --James # by BlueRevolution on 10/23/04 at 23:52:21if you want to get rid of the "mozilla" and "netscape" texts from the title just remove everything after the last hyphen in the returned string (gained from years of painful VB programming *shudder*)
# by on 02/05/05 at 05:30:41Firefox actually has minimal scripting support. No need for all the icky UI scripting :)
Look at all the info this gets you: tell application "Firefox" get properties of front window end tell # by schinckel on 08/14/05 at 09:47:42With recent versions of Camino, you can replace all of the ugly code with:
on substitute() tell application "Camino" «class curl» of window 1 set myURL to the result set myTitle to name of window 1 end tell return "" & myTitle & "" end substitute (I hope this doesn't mangle my html, it's my first post). It's faster, and no window popping. Post a New CommentYou must be logged in to post comments. |
# by BlueRevolution on 10/23/04 at 07:04:18