Firefox - Default Homepage for New Users
Hi all,
We are looking at delivering Firefox 3.0.9 in a corporate environment.
Most of the required settings for new users have already been set via entries in the "C:\Program Files\Mozilla Firefox\defaults\pref\firefox.js" file - such as set proxy url / disable autoupdate / disable default browser check etc.
However I've not yet been able to find out how to set the default homepage for new users.. We need it set to our intranet address and we don't want users to have to change it themselves via the GUI or via the about:config utility
The only way I've found to do it so far is to create "C:\Documents and Settings\username\Application Data\Mozilla\Firefox\Profiles\r2dpqqup.default\user.js" containing;
user_pref("browser.startup.homepage", "http://intranetaddress");
However since this can't be done until the random profile folder name (r2dpqqup.default in this example) is created during first run - it is not a solution.
I can't find a solution on the web, and there is nothing about setting the default home page in the AppDeploy KB. This can no doubt be achieved by scripting something but it seem such an obvious request that it must be possible through native Firefox config - surely?!
Regards,
Rob.
We are looking at delivering Firefox 3.0.9 in a corporate environment.
Most of the required settings for new users have already been set via entries in the "C:\Program Files\Mozilla Firefox\defaults\pref\firefox.js" file - such as set proxy url / disable autoupdate / disable default browser check etc.
However I've not yet been able to find out how to set the default homepage for new users.. We need it set to our intranet address and we don't want users to have to change it themselves via the GUI or via the about:config utility
The only way I've found to do it so far is to create "C:\Documents and Settings\username\Application Data\Mozilla\Firefox\Profiles\r2dpqqup.default\user.js" containing;
user_pref("browser.startup.homepage", "http://intranetaddress");
However since this can't be done until the random profile folder name (r2dpqqup.default in this example) is created during first run - it is not a solution.
I can't find a solution on the web, and there is nothing about setting the default home page in the AppDeploy KB. This can no doubt be achieved by scripting something but it seem such an obvious request that it must be possible through native Firefox config - surely?!
Regards,
Rob.
0 Comments
[ + ] Show comments
Answers (17)
Please log in to answer
Posted by:
dunnpy
13 years ago
Rob,
There is some information in the KB for Firefox 2.x which may be revelant:
"In file "localized\browserconfig.properties" set browser.startup.homepage and browser.startup.homepage_reset to your preferred homepage"
It's been a while since I've done a FF package, but I think I changed the setting above in the flat install files and then snapped the installation.
The client wanted every new version packaged, so once I'd made the config change once I copied the altered files into the flat install files for each new version and never need to check them again - sorry I can't be more help.
Thanks,
Dunnpy
There is some information in the KB for Firefox 2.x which may be revelant:
"In file "localized\browserconfig.properties" set browser.startup.homepage and browser.startup.homepage_reset to your preferred homepage"
It's been a while since I've done a FF package, but I think I changed the setting above in the flat install files and then snapped the installation.
The client wanted every new version packaged, so once I'd made the config change once I copied the altered files into the flat install files for each new version and never need to check them again - sorry I can't be more help.
Thanks,
Dunnpy
Posted by:
rumcaiz
13 years ago
I did Firefox package yesterday and i did it other way.
first i created my mozilla.txt file (name should be anything.txt) containing options i want preconfigure. in my case it was:
//
lockPref("app.update.auto", false);
lockPref("app.update.mode", 0);
lockPref("app.update.enabled", false);
lockPref("browser.rights.3.shown", true);
lockPref("browser.startup.homepage", http://myhomepage);
lockPref("browser.shell.checkDefaultBrowser", false);
then transfered it using byteshift13 to mozilla.cfg (you can use http://www.alain.knaff.lu/howto/MozillaCustomization/cgi/byteshf.cgi which does that automaticaly) and this cfg file one must save to c:\Program Files\Mozilla Firefox\ (or wherever you installdir is)
as you can see i wanted theese locked preferences as nobody can change it after installation (without appropriate knowledge), you can use user_pref if you want it changable
next i add one line at the bottom of tha all.js file (which is stored in c:\Program Files\Mozilla Firefox\greprefs\)
the line is (beware of your cfg file naming, this line must have your cfg name):
pref("general.config.filename", "mozilla.cfg");
its good to create override.ini file too, in your c:\Program Files\Mozilla Firefox\ for not to migrate profile (and not to run installation again when app is run)
this override.ini has lines:
[XRE]
EnableProfileMigrator=false
first i created my mozilla.txt file (name should be anything.txt) containing options i want preconfigure. in my case it was:
//
lockPref("app.update.auto", false);
lockPref("app.update.mode", 0);
lockPref("app.update.enabled", false);
lockPref("browser.rights.3.shown", true);
lockPref("browser.startup.homepage", http://myhomepage);
lockPref("browser.shell.checkDefaultBrowser", false);
then transfered it using byteshift13 to mozilla.cfg (you can use http://www.alain.knaff.lu/howto/MozillaCustomization/cgi/byteshf.cgi which does that automaticaly) and this cfg file one must save to c:\Program Files\Mozilla Firefox\ (or wherever you installdir is)
as you can see i wanted theese locked preferences as nobody can change it after installation (without appropriate knowledge), you can use user_pref if you want it changable
next i add one line at the bottom of tha all.js file (which is stored in c:\Program Files\Mozilla Firefox\greprefs\)
the line is (beware of your cfg file naming, this line must have your cfg name):
pref("general.config.filename", "mozilla.cfg");
its good to create override.ini file too, in your c:\Program Files\Mozilla Firefox\ for not to migrate profile (and not to run installation again when app is run)
this override.ini has lines:
[XRE]
EnableProfileMigrator=false
Posted by:
MSIPackager
13 years ago
Posted by:
jcarri06
13 years ago
Rob,
I also think you can create your user.js file under C:\Program Files\Mozilla Firefox\defaults\profile so that whenever a user launches FF, it will pull this users.js file onto the random folder it creates under the user's profile. I'm pretty sure that's how I accomplished it last time I did FF.
- Jay
I also think you can create your user.js file under C:\Program Files\Mozilla Firefox\defaults\profile so that whenever a user launches FF, it will pull this users.js file onto the random folder it creates under the user's profile. I'm pretty sure that's how I accomplished it last time I did FF.
- Jay
Posted by:
MSIPackager
13 years ago
Posted by:
reds4eva
13 years ago
Ive been using the "prefs.js" file, not a "users.js" file, which is in the location Jay says it is above, C:\Program Files\Mozilla Firefox\defaults\profile. If that file doesnt exist in the random profile name then it copies it from above location. Its all good until the file or random profile already exists, then it becomes a pain.
Posted by:
nheim
13 years ago
Hi Rob,
just an input:
We use Group Policies to do things like this.
Initially, we used this extension:
http://in-cider.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&_c=BlogPart&partqs=cat%3dGroup%2520Policy%2520Firefox%2520Extension
Nowadays, we just use the code from it and append it to "nsBrowserContentHandler.js".
With this, you can set defaults or lock more or less all the prefs in FF via GPO.
Regards, Nick
just an input:
We use Group Policies to do things like this.
Initially, we used this extension:
http://in-cider.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&_c=BlogPart&partqs=cat%3dGroup%2520Policy%2520Firefox%2520Extension
Nowadays, we just use the code from it and append it to "nsBrowserContentHandler.js".
With this, you can set defaults or lock more or less all the prefs in FF via GPO.
Regards, Nick
Posted by:
MSIPackager
13 years ago
Perfect, thanks Nick - if this gets past POC then GP would definately be preferred to manage this stuff.
I haven't had a look at it yet but do you know off hand if the GP can handle Certificates? We need to install a trusted root certificate (called "Authorities" in FF) and at the moment it's a manual process for end users. There doesn't seem to be a command line utility to register the .CER file automatically either - so this is potentially an issue.
Thanks,
Rob.
I haven't had a look at it yet but do you know off hand if the GP can handle Certificates? We need to install a trusted root certificate (called "Authorities" in FF) and at the moment it's a manual process for end users. There doesn't seem to be a command line utility to register the .CER file automatically either - so this is potentially an issue.
Thanks,
Rob.
Posted by:
jcarri06
13 years ago
Posted by:
MSIPackager
13 years ago
Thanks, some useful tips there.
I already had the override.ini but locking the other preferences will be very useful.
Edit: Anyone using the above lockPrefs - ensure you put your homepage in quotes or you'll get an error reading configuration file when you run Firefox... [;)]
lockPref("browser.startup.homepage", "http://myhomepage");
There's a definitive list of settings here: http://kb.mozillazine.org/About:config_entries
Regards,
Rob.
I already had the override.ini but locking the other preferences will be very useful.
Edit: Anyone using the above lockPrefs - ensure you put your homepage in quotes or you'll get an error reading configuration file when you run Firefox... [;)]
lockPref("browser.startup.homepage", "http://myhomepage");
There's a definitive list of settings here: http://kb.mozillazine.org/About:config_entries
Regards,
Rob.
Posted by:
ramesh111k
13 years ago
Hi Rob,
I have used the some (below are some) parameters in the text file and converted them into a config file. The mozilla.cfg is working fine for users in controlling the settings but the administrators are also not able to change the settings.
Am I going in wrong direction or by default will this mozilla.cfg file will not allow users as well as administrators not to change the settings of firefox ?
Our client requirement is to allow only administrators to change the settigns and control the users not to change any settings.
Please suggest :)
Lockpref("app.update.enabled", false);
Lockpref("network.proxy.type", 0);
Lockpref("browser.startup.page", 1);
userpref("browser.startup.homepage", "http://Google.com/");
Regards
Ramesh
I have used the some (below are some) parameters in the text file and converted them into a config file. The mozilla.cfg is working fine for users in controlling the settings but the administrators are also not able to change the settings.
Am I going in wrong direction or by default will this mozilla.cfg file will not allow users as well as administrators not to change the settings of firefox ?
Our client requirement is to allow only administrators to change the settigns and control the users not to change any settings.
Please suggest :)
Lockpref("app.update.enabled", false);
Lockpref("network.proxy.type", 0);
Lockpref("browser.startup.page", 1);
userpref("browser.startup.homepage", "http://Google.com/");
Regards
Ramesh
Posted by:
MSIPackager
13 years ago
Can't see how you'd achive the granualar acccess you require with this method.
Probably best using Group Policy as Nick suggested above - although I didn't investigate that at all so can't comment on how good it is.
Regards,
Rob.
Probably best using Group Policy as Nick suggested above - although I didn't investigate that at all so can't comment on how good it is.
Regards,
Rob.

so that the conversation will remain readable.