4 Replies Latest reply: Feb 17, 2014 9:22 AM by Ebonweaver
dnorth12 Level 1 Level 1 (10 points)

I can't be certain, but I seem to remember there was a setting in Safari for deleting history and cookies upon closing the application automatically. I can't seem to find that setting. It appears to me that the only way to do that now is manually at the end of each session.

 

The problem I am having is that each time I open Safari I have all the previous tabs from previous use opening if I haven't manually deleted their history before closing Safari on the previous use.

 

I know this works in Firefox, which I use frequently. I am using Safari to record online streaming audio via Audio Hijack and I sometimes end up with multiple tabs open and am getting multiple audio sources. Audio Hijack has a timer that opens and closes Safari, but no control over the history that is created in Safari.

 

 

I would appreciate some help if anyone is so inclinded. Thank you.


iMac (27-inch Mid 2011), Mac OS X (10.7.4)
  • 1. Re: Delete history/cookies on closing Safari
    andyBall_uk Level 7 Level 7 (20,305 points)

    Safari 6.0.5 has a setting : Preferences - General - Safari opens with...

    if that's set to ' a new window ' rather than 'all windows from last session' and you still have the issue, then check System Preferences - General - Close windows when quitting an application.

  • 2. Re: Delete history/cookies on closing Safari
    dominic23 Level 7 Level 7 (20,915 points)

    As far as I know there is no preference setting available in Safari to accomplish that.

     

    Hold shift key down and launch Safari to suppress the resume feature.

     

    But that does neither clear cookies nor history.

  • 3. Re: Delete history/cookies on closing Safari
    dnorth12 Level 1 Level 1 (10 points)

    Andy,

     

    This resolves the issue for me. I have set safari to open to a blank page and then let Audio Hijack set the page I want. No more multiple tabs opening from previous session.

     

    Thanks.

  • 4. Re: Delete history/cookies on closing Safari
    Ebonweaver Level 1 Level 1 (0 points)

    Old thread I know, but in regard to clearing cache and history on exit... that never has a good answer from what I have found.  Since there is no way in the app or with any extension I can find to do this, the only method I see is lock down the files it writes to.

     

    First, open Safari and clear the history, the quit.

    Delete the contents of ~/Library/Caches/com.apple.Safari/Webpage Previews

    In terminal remove write permisons (chmod a-w) on these files:

    ~/Library/Caches/com.apple.Safari/Webpage Previews

    ~/Library/Caches/com.apple.Safari/Caches*

    ~/Library/Safari/History.plist

    Get info ~/Library/Safari/History.plist and check the box to make it locked.

     

    Now Safari will show history while it's open, but can not write it out when you quit so it will not be saved, and the hundreds of megs of page preview caches will not be saved.

     

    I haven't tested cookie blocking, but my assumption is you remove write and lock ~/Library/Cookies/com.apple.Safari.SafeBrowsing.binarycookies.