how to get new urls to open in a different page
how to get new urls to open in a different page
- Subject: how to get new urls to open in a different page
- From: "Ken G. Brown" <email@hidden>
- Date: Thu, 16 Oct 2008 13:18:39 -0600
Title: how to get new urls to open in a different
page
I am using the following script to open a
set of www sites in tabs on a single Safari page.
-- an
applescript program that opens a list of urls in separate
tabs.
set
urlList to
{"http://finance.yahoo.com/q?s=aapl",
"http://www.apple.com",
"http://www.macfixit.com"}
set
numURLs to
(count
urlList)
tell application "Safari"
make new document with
properties {URL:(item 1 of urlList)}
set this_win to (window 1)
repeat with
jj from
2 to
numURLs
tell
this_win
make new tab with
properties {URL:(item jj of urlList)}
end tell
end repeat
end tell
Works pretty nicely except I'm
finding that once I execute this script, Safari always wants to open
any new links from my email program as a new tab on this same page,
even though I have subsequently opened a new page in Safari and have
it as the window in focus.
I have Safari preferences set to open links from other
applications in a new tab on the current page which is what I want,
but the current page always remains pointed to the one I opened with
the script. It works correctly as long as I have not previously
executed the script.
Problem is, then the page with all the tabs ends up pointing to a
page I do not recognize as one on my multi-tabbed page, in the list of
open windows and when I have a lot of open windows, it becomes a
problem to find my wanted page. I use the script to open a list of
stocks I am following and want to quickly get back to it often
throughout the day.
Any ideas what needs to be done to fix this anomaly?
Thx for any tips.
Ken G. Brown
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden