Skip navigation

Can AS Choose Bookmarks Open In Tabs?

1862 Views 6 Replies Latest reply: Feb 8, 2011 12:24 PM by beckmart RSS
BioRich Level 1 Level 1 (65 points)
Currently Being Moderated
Dec 8, 2010 3:05 AM
Hi folks.

After scanning the Safari dictionary, I was wondering if I can integrate choosing a bookmarks folder to be opened in tabs. I develop using about 8 tabs and I often choose that. I would like to trigger that by using a script. Can this be done?

I have the bookmarks in a current folder, and it would be nice to be able to point to that locus. However, from the looks of the library, I'd have to open each tab individually with a direct URL.

In any case, happy to hear what people have found.

Cheers
G5 1.8, Blackbook 2.0, Mac Pro 2.8 (8c), iMac 17 2.0, Touch2, Shuffle2, iPod40, Mac OS X (10.6.5), iPhone? Heck I'm still giggly about MultiFinder!
  • Bernard Harte Level 4 Level 4 (3,025 points)
    Currently Being Moderated
    Dec 8, 2010 12:10 PM (in response to BioRich)
    This script will take a list of URLs and open them in tabs in a single document - which is, I think, what you are asking for with the exception of the folder part (see below). If not what you want, do elaborate.

    When you say you have the bookmarks in a current folder, are you referring to a Safari bookmark folder or a set of weblocs in a Finder folder?


    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px;
    color: #000000;
    background-color: #FFDDFF;
    overflow: auto;">
    set bookmarkList to {"http://discussions.apple.com/", "http://www.apple.com/", "http://www.macintouch.com/"}
    tell application "Safari"
    make new document at end of documents
    set URL of document 1 to item 1 of bookmarkList
    set bookmarkList to items 2 thru end of bookmarkList
    repeat with theBookmark in bookmarkList
    make new tab at end of tabs of window 1 with properties {URL:theBookmark}
    end repeat
    end tell </pre>
    MacBook Pro, Mac OS X (10.6.5), High-Res 17" 2.5GHz 4GB
  • Bernard Harte Level 4 Level 4 (3,025 points)
    Currently Being Moderated
    Dec 8, 2010 4:19 PM (in response to BioRich)
    I think you're going to have to parse the Bookmarks.plist to get what you want.

    Considering this functionality is a single choice from a menu in Safari, I guess this is part of a bigger project? If you share that aim, you might get more help here.
    MacBook Pro, Mac OS X (10.6.5), High-Res 17" 2.5GHz 4GB
  • Bernard Harte Level 4 Level 4 (3,025 points)
    Currently Being Moderated
    Dec 8, 2010 4:25 PM (in response to BioRich)
    I am sure someone here could tell you how to get to the nested folder with GUI scripting, but that's not my forté.
    MacBook Pro, Mac OS X (10.6.5), High-Res 17" 2.5GHz 4GB
  • beckmart Level 1 Level 1 (25 points)
    Currently Being Moderated
    Feb 8, 2011 12:24 PM (in response to BioRich)
    Hi,

    it's already a while ago that you asked your question.

    FYI: Quicksilver (free and OpenSource http://qsapp.com/) lets you easily jump to each bookmarks folder in the Safari bookmarks and open all its contents.

    In the tutorials section of the QS wiki (http://qsapp.com/wiki/Tutorials) you'll find the link to Howard Melman's excellent Quicksilver Manual which explains how to use it (just search for bookmarks).

    (Quicksilver is such a powerful tool and I don't know what I would do without it on my mac..)

    Kind regards

    Martin
    MacBook 13" white 2,16 GHz, 3 GB RAM, Mac OS X (10.6.5)

Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)

Legend

  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.