Terminal Tips: Force Safari to open all links in new tab
Firefox users have been able to open all links clicked within Firefox in a new tab for a while now, but what about us poor Safari users? Well, sure, you could always hold down command while clicking a link, but that's not fun, now is it? With this simple Terminal hack, you will be surfing like a pro! Just open Terminal (/Applications/Utilities/) and type in the following command:
defaults write com.apple.Safari TargetedClicksCreateTabs -bool true
Want more tips and tricks like this? Visit TUAW's Mac 101 and Terminal Tips sections.
Share
Categories
Firefox users have been able to open all links clicked within Firefox in a new tab for a while now, but what about us poor Safari users?...
Add a Comment
@Johan S.: you're the reason we can't have nice things.
@Everyone else: the important thing about this is that it overrides evilness like _blank--particularly whatever black magic gmail uses that makes Safari completely ignore tab and command-key settings.
Now you mention it. Is there a reason links on tuaw never have the '_blank' set as target. It's so annoying having to puch back back back or retyping the url.
September 08 2008 at 2:07 PM Report abuse Permalink rate up rate down ReplyIt will work, but thats not the point, in firefox, using your third button (if you have the 4 button apple mighty mouse then you can set up the scroll ball click function to be the third button) you can open it in a new tab, while left mouse button will do ordinary in-tab open. And using the third mouse button works in safari too, just like in firefox, so if you want the functionality, i would say it would be better to get a mighty mouse for your mac! I wouldn't always want to open links in a new tab, only sometimes, but for people who want to open every link in a new tab, then this would work great.
September 08 2008 at 12:14 PM Report abuse Permalink rate up rate down ReplyI must be a clutz, but isn't this repeating the same entry as this one:
http://www.tuaw.com/2008/03/21/terminal-tip-safari-3-1-brings-true-one-window-mode/
as i posted before... yes ;)
September 08 2008 at 12:53 PM Report abuse Permalink rate up rate down ReplyThis one doesn't work on Safari 4 developer preview 1.
September 08 2008 at 11:44 AM Report abuse Permalink rate up rate down ReplyIs there a way to open 'new' windows in a new tab? This is a feature that I love in mozilla. Most links open in the same window, but those links that ask the browser to open in a new window actually get opened in a new tab.
September 08 2008 at 11:27 AM Report abuse Permalink rate up rate down Replythanks what this will do. It's not quite every link. If something is supposed to stay in the same widow, it does or at least that's been my experience.
Try it out for an hour or 2.
I'd be a happy camper if there was a command-click equivalent in Mobile Safari. Hold down the link for two seconds, get an option to open in a new tab.
Actually, if you Command-click a link, it will open in a new tab (as long as the preferences are set as such).
September 08 2008 at 12:10 PM Report abuse Permalink rate up rate down ReplyHe said "MOBILE Safari", meaning iPhone/iPod touch. I agree, that's one thing Windows Mobile got right -- click-and-hold = right-click. I *HATE* not being able to open a new page from a link when using my phone.
September 08 2008 at 2:38 PM Report abuse Permalink rate up rate down ReplyOK, so how do I get Mail.app to either make a new tab in the current window or stop popping a new window UNDER my current one?
September 08 2008 at 10:50 AM Report abuse Permalink rate up rate down ReplyYou can enable that in the "General"-Tab of the Safari Prefs. "open links from Applications" - click on "in a new tab in the current window"
September 08 2008 at 10:52 AM Report abuse Permalink rate up rate down ReplyNote that this causes strange behaviour in Safari 4 DP. If you click on Links that should create these small undecorated Popups (like Help or something), Safari wont open them in Popups anymore but will resize the whole Window (with your 20 Tabs) and will remove your Address-Bar. The only way to restore Safari then is to close and re-open the window.
Had to disable this feature.
BTW: You had that tip already a few months ago ;)
Thanks. I wanted to mention this too! It is the most annoying thing.
But, you don't have to close the window to get things back. All safari does is reset the window to whatever that site specified. Most of the time there is no bookmarks or URL. To get everything back it's simple.
Hold CMD-Shift and then press | (shift backslash) then B and then T and that will show the address bar book marks and then tabs. Somehow, adding back the address bar and bookmarks makes the tab bar go away.
Same thing happened to me! Had to disable as well...
Almost forgot what was causing it and then remembered this mod...
Too bad... At least FF3 is still my main browser and Safari is just for random stuff and testing... :)
Why on God's green Earth would you want EVERY link to open in a new tab? Middle mouse button FTW!
September 08 2008 at 10:29 AM Report abuse Permalink rate up rate down ReplyHot Apps on TUAW
Deals of the Day
more deals- JVC Motion Sensing Clock Radio with Dual iPod Docks for $55 + free shipping
- Apple iPhone Headset with Mic for $4 + $2 s&h
- miFrame Picture Frame Dock for iPad for $64 + $8 s&h
- Refurb Apple iPod nano 8GB MP3 Player for $99 + free shipping, 16GB for $119
- Hannspree Apple-Shaped 28" 1080p LCD HDTV for $270 + free shipping
- Philips wOOx Alarm Clock Radio for Apple iPod / iPhone for $60 + free shipping
Software Updates
more updates- EFI Firmware Update brings Lion Internet Recovery to 2010-model Macs
- OS X Lion 10.7.3 released with Safari 5.1.3, Wi-Fi bug fix
- Aperture updated to 3.2.2, addresses Photo Stream issue
- Apple updates Keynote to address Lion issues
- Google Search app gets new look on iPad
- Apple releases Apple TV Software Update 4.4.3



21 Comments