Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

whenpaulsparks

macrumors regular
Original poster
Jun 5, 2004
210
1
Tallahassee, FL
I was looking for a way to disable private browsing in Safari. so i looked and looked and couldn't find one, until i remembered that a lot of Apple apps have the NIB (interface builder) files in the application package. so here's how to disable the "Private Browsing" menu option in safari, effectively disabling private browsing!

(you must have Xcode tools installed... its a free download from apple.com but also included with newer macs. and putting up a modified binary would be futile, because it will be changed every safari/mac os x update, so whenever you update the software, make sure to follow these steps again.)

1. Go to applications folder in Finder
2. right click (with a mighty mouse or 2 button mouse, or Control+click for one button mice) on safari and choose "Show Package Contents"
3. Go to Contents, then Resources, then English.lproj folder (or a respective folder for whatever language you have maybe)
4. Double click on MainMenu.nib to open it in interface builder
5. look at the window with the safari menu, click on Safari to expand it, then click on the Private Browsing menu item.
6. hit the delete key and it disappears!
7. hit command+s to save, close interface builder if you want, and relaunch safari.

and there, no more private browsing option! hope this helps everyone.
 
  • Like
Reactions: Shirasaki

36183

Guest
Jun 24, 2004
418
0
good find!

I am sure all parents will find it useful but i think many people will intentionally ignore this article.

out of interest is it possible to edit the interface file to add functionality to the safari menus? and if so what can be added?
 

whenpaulsparks

macrumors regular
Original poster
Jun 5, 2004
210
1
Tallahassee, FL
since the source code isn't available, i think the only thing you can *add* would be an applescript command from a menu item, to run a script or something, since there's an applescript part of interface builder.
 

soaerang

macrumors newbie
Feb 3, 2006
3
0
Help, Please!

I'm having trouble following the instructions above and would greatly appreciate any help. I get to step four and am able to click on the folder "MainMenu.nib", however once I go there, I can't seem to open it in interface builder. I see interface builder, but I'm not quite sure how to open up the "MainMenu.nib" folder in the interface builder. In the MainMenu.nib folder, I only have three options ("classes.nib", "info.nib", and "objects.nib") I apologize if this is all no brainer stuff...just moved to macs not too long ago. I downloaded and installed Xcode Tools, but it still doesn't seem to be working.

Thanks for helping a newbie out!
 

soaerang

macrumors newbie
Feb 3, 2006
3
0
oh, nevermind! i figured out how to do it! thank you so much for your help anyway! :)
 

orchid123

macrumors newbie
Oct 16, 2006
1
0
Can someone help with step 4?

I realize this is an old thread but I need help with step 4 as well..

Once I opened up mainemnu.nib it opened omnigraffle pro and from there I am lost!

These are the steps I need help with.

4. Double click on MainMenu.nib to open it in interface builder
5. look at the window with the safari menu, click on Safari to expand it, then click on the Private Browsing menu item.
6. hit the delete key and it disappears!
7. hit apple+s to save, close interface builder if you want, and relaunch safari.

Thanks!
 

WildCowboy

Administrator/Editor
Staff member
Jan 20, 2005
18,390
2,829
Do you have Xcode/Developer Tools installed?

If so, right-click or control-click on MainMenu.nib and go to Open With and choose Interface Builder.
 

excitinglife

macrumors newbie
Oct 28, 2006
1
0
Is Disabling Private Browsing in Safari irreversible?

I was considering disabling Private Browsing in Safari based on these instructions.

However, I wonder if it is irreversible before doing so. Does anyone know if it is and if so, what needs to be done to make it happen?
 

Texas04

macrumors 6502a
Jul 2, 2005
886
1
Texas
Why dont you password your mac... make a "roomate" username and enable parental controls...
I have it so that after sleep or screen saver it asks for my password

http://www.iAlertU.com if you dont want them messin w/ it :)
 

semaja2

macrumors 6502a
Dec 12, 2005
576
18
Adelaide
Why dont you password your mac... make a "roomate" username and enable parental controls...
I have it so that after sleep or screen saver it asks for my password

http://www.iAlertU.com if you dont want them messin w/ it :)

Why not MultiAlarm :p sure the support for mouse and keyboard movement is buggy but still does its job :p

PS. I think ill make a script to remove that option, problem still remains that the user needs XCode
 

macgirl22

macrumors newbie
Jan 23, 2010
1
0
Help

Hello whenpaulsparks. I have tried the steps listed as recommended by and and others and I got to the part :
Go to applications folder in Finder
2. right click (with a mighty mouse or 2 button mouse, or Control+click for one button mice) on safari and choose "Show Package Contents"
3. Go to Contents, then Resources, then English.lproj folder (or a respective folder for whatever language you have maybe)
4. Double click on MainMenu.nib to open it in interface builder
I am not able to double click on this and when I do nothing happens. No window pops up or anything. 2 pages to the right of it appears and those I can't even open.
I would appreciate your help. Thanks
 

jumbb

macrumors regular
May 1, 2010
103
0
Hi whenpaulsparks!
I used to be able to do this with xcode but recently, i installed safari 4.0.5 for Leopard and I can't do it anymore!
This is what appears:

picture1af.png



I don't know what to do! Some people have told me it's no longer possible, but...what can I do now? Do you have any more ways to do this? Thanks!
 

Darwin-ksh

macrumors newbie
Feb 17, 2010
17
0
since the source code isn't available, i think the only thing you can *add* would be an applescript command from a menu item, to run a script or something, since there's an applescript part of interface builder.

Are you sure there isn't any source available? I was under the impression that only the GUI was closed source and Safari was just cleaned up Webkit.
 

MKRoig

macrumors newbie
Aug 8, 2010
1
0
Hi whenpaulsparks!
I used to be able to do this with xcode but recently, i installed safari 4.0.5 for Leopard and I can't do it anymore!
This is what appears:

picture1af.png



I don't know what to do! Some people have told me it's no longer possible, but...what can I do now? Do you have any more ways to do this? Thanks!

I'm having the same problem only I have safari 5.0 any help would be greatly appreciated!
 

spoiledmatt

macrumors newbie
Nov 9, 2010
1
0
Private Browsing

I am in the same boat....When I double click on the MainMenu.nib, I receive

"the document"mainmenu.nib" could not be opened. Interface Builder cannot open compiled nibs. Try opening the source docuement instead of the compiled nib."

If anyone could help it would be greatly appreciated!
 

sth

macrumors 6502a
Aug 9, 2006
571
11
The old world
Just a quick question: Why would anyone want to do that?

You can delete your history, cookies and cache even without having the private browsing option, so hiding it won't hinder anyone...
 

kystherayn

macrumors newbie
Oct 29, 2010
1
0
disable private browsing

I know this is a very old thread, but i have tried those steps several times and it does not work. I have mac osx 10.6.4
 

cherry su

macrumors 65816
Feb 28, 2008
1,217
1
I was considering disabling Private Browsing in Safari based on these instructions.

However, I wonder if it is irreversible before doing so. Does anyone know if it is and if so, what needs to be done to make it happen?

It is reversible. Before modifying the file, you could copy the original version to a safe location. If you have a Time Machine Backup of Safari, then you are covered.
 

sginmackenzie

macrumors newbie
Dec 30, 2009
2
0
Maybe I'm the only one...

Ok, so I'm trying to follow these directions, and here's what I'm getting:

Safari > Contents > Resources > English.lproj > MainMenu.nib (it's a folder) > keyedobjects.nib (un-opening file)

Am I missing something? I'm not even seeing an option for a "mainmenu.nib" file to open. Any insights here?:confused::confused::confused:
 

ArtOfWarfare

macrumors G3
Nov 26, 2007
9,561
6,059
Just a quick question: Why would anyone want to do that?

You can delete your history, cookies and cache even without having the private browsing option, so hiding it won't hinder anyone...

For the same reason why anyone would want Private Browsing, namely the convenience.

Im suffering relapses right now so anything I can do to make it take just a bit longer, make it just a bit less convenient, give me just a few more seconds to think about before doing, short of actually impairing my ability to do productive things, is a blessing.

Unfortunately, this is no longer an option. Looks like I'll just need a stronger will...
 
  • Like
Reactions: Psgirl119

schwarzmuller

macrumors newbie
Jan 11, 2011
14
0
Because safari now uses precompiled nib's which u can't modify:

I took the MainMenu.nib from an older version of safari.
Just open the file, of your language, with interfacebuilder and delete what you want. Make a copy of the original mainmenu.nib and replace it with the modifyd one.
I don't know if the safari menu changed a lot, since i don't use that browser. I did a quick test and it works ok.

Enjoy :)

Edit: Files are one post below and are pre-modified.
 
Last edited:

hellroc

macrumors newbie
Mar 24, 2011
1
0
im stuck at number 5 where is the window?

I was looking for a way to disable private browsing in Safari. so i looked and looked and couldn't find one, until i remembered that a lot of Apple apps have the NIB (interface builder) files in the application package. so here's how to disable the "Private Browsing" menu option in safari, effectively disabling private browsing!

(you must have Xcode tools installed... its a free download from apple.com but also included with newer macs. and putting up a modified binary would be futile, because it will be changed every safari/mac os x update, so whenever you update the software, make sure to follow these steps again.)

1. Go to applications folder in Finder
2. right click (with a mighty mouse or 2 button mouse, or Control+click for one button mice) on safari and choose "Show Package Contents"
3. Go to Contents, then Resources, then English.lproj folder (or a respective folder for whatever language you have maybe)
4. Double click on MainMenu.nib to open it in interface builder
5. look at the window with the safari menu, click on Safari to expand it, then click on the Private Browsing menu item.
6. hit the delete key and it disappears!
7. hit command+s to save, close interface builder if you want, and relaunch safari.

and there, no more private browsing option! hope this helps everyone.
im stuck at number 5 where is the window?
 

mummabear

macrumors newbie
Jun 10, 2011
1
0
Thank you for this information on how to disable Safari. I used the pre modified folders today. Does anyone have feedback on how well they work? I would also appreciate more help on parental controls.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.