Tricks and hidden features in Mozilla

Status
Not open for further replies.

Phantasm66

Posts: 4,909   +8
Some interesting things here, including how to kid web servers on that your mozilla browser is IE or something, useful when certain sites like on-line banking tell you to get lost because you "aren't using a Windows or Apple Mac Operating System..." Hmmm....


Tricks and hidden features in Mozilla

Last updated on Sat, 05 May 2001

This covers tricks and some hidden preferences in Mozilla. Although this sounds similar to that can be used with Mozilla. A Tips and suggestions for using Mozilla, which is about usage tips and advice, this page focuses more on little preferences and features.

The following customizations only take effect after restarting Mozilla, and a simple text editor is required to create and edit the proper files:

Customizing Appearances
Hidden Preferences
Customizing Appearance
Much of Mozilla's colors and appearance is colored with Cascading Style Sheet files, so Mozilla's appearance can be customized with two CSS files: userContent.css and userChrome.css

These files must be placed in the chrome folder of your Mozilla profile, not the chrome folder where Mozilla was installed.

userContent.css overrides certain appearance settings of within the content window of the browser and Mail/News, while userChrome.css controls the UI chrome of Mozilla. For example, the following for userContent.css will put a thin black border around all dropdown forms, like in Netscape 4.x:

:-moz-dropdown-list {
border: 1px solid black !important;
border-top-style: solid !important;
}

To customize the font for dialog windows, place the following in userChrome.css and modify to your heart's delight:

window {
font-size: 3.5mm !important;
font-family: helvetica !important;
}

Visit mozilla.org for more examples of these CSS customizations.

Hidden Preferences
Mozilla keeps many of its preferences in the file prefs.js in your Mozilla profile. You can create your own file, user.js, at the same location as the prefs.js file, to store your custom preferences. Mozilla will read the user.js file and overrule some settings in prefs.js with them.

One useful preference setting that can be added to user.js is for controling of animated images:

user_pref("image.animation_mode", "value");

where value is either normal, once, or none. The default setting is normal, but once prevents animated images from looping after its first run, while none prevents it from animating at all.

If you visit a site that is blocking your browser from entering, the following preference will help with that:

user_pref("general.useragent.override", "fake agent string");

fake agent string can be any browser you choose, and over-rides the standard user agent string that Mozilla identifies itself as to servers and JavaScript. For example, if the site only allows Internet Explorer users, then either of the following will overcome this problem and trick the server or offending JavaScript:

user_pref("general.useragent.override", "Mozilla/4.0 (compatible; MSIE 5.0; Mac_PowerPC)");

user_pref("general.useragent.override", "Mozilla/4.0 (compatible; MSIE 5.0; Windows 98; DigExt)");

Although this does not affect Mozilla's browser behavior or emulate the rendering of the browser specified in the string, it can be very useful if you need to test the reaction of a JavaScript or server-side script to different browsers.

source: http://www.gerbilbox.com/newzilla/mozilla/usingmoz10.php

see also:
http://www.gerbilbox.com/newzilla/mozilla/usingmoz09.php
http://mozilla.org/unix/customizing.html#usercss
http://mozilla.org/unix/customizing.html#prefs
 
Status
Not open for further replies.