[wpkg-users] Firefox Proxy - unlocked

Malte Starostik malte at malte.homeip.net
Fri Mar 5 10:23:12 CET 2010


Am Donnerstag, 4. März 2010 20:48:38 schrieb Justin Brinegar:
> >> there are some that will not default.  Specifically, I encountered
> >> issues with defaulting the homepage in Firefox 3.5.  In Thunderbird (and
> >
> > I'm still using 3.0, but i simply use:
> >
> > 	pref("browser.startup.homepage", "http://www.sv.lnf.it/");
> > 	pref("browser.startup.page", 1);

pref() should be avoided, it allows the user to change the value, but on next 
startup it will be overridden with the value passed to pref() again.  
defaultPref() works better in that it only applies if the preference is not 
set in the user's prefs.js already.

> > and works..
> 
> I ended up putting this in the default profile (using user_pref() in
> prefs.js).  It affects new user Firefox profiles, but not old ones.  It
> simply would not default correctly if I used defaultPref in the config
> file.  I tried it on 2.X and it worked, tried it on 3.0 and it worked,
> but 3.5.2 didn't and I don't know if it has been fixed.

The homepage is somewhat special as its value is indirected to allow for 
easier localisation.  It has to point to a resource URL like this:

defaultPref("browser.startup.homepage", "resource:/custom.properties");
defaultPref("browser.startup.page", 1);

Where custom.properties (or whatever you called it in the preference value) is 
a file directly in the firefox installation directory that contains a line 
with the actual homepage URL:

browser.startup.homepage=http://www.example.com/

If that is all you need your mozilla.cfg for, you could get rid of it 
alltogether and instead just customise the default resource file, 
browserconfig.properties, but it will be overwritten whenever a new version of 
firefox is installed.

HTH,
Malte



More information about the wpkg-users mailing list