Under IE, we can easily use the following code to implement the Settings home page:
Click here to make devdao.com your default homepage!
[Ctrl + A All SELECT Note: If the need to introduce external JS need to refresh to perform]
However, it's not going to work under Firefox.
To use a script to set up a home page under Firefox, you must first confirm that in the browser's "About:config",
Signed.applets.codebase_principal_support
Set to True
Then use the following script:
<textarea id="runcode91896"><script language= "JavaScript" > Function setHomePage () {if (document.all) {document.body.style.behavior= ' URL (#default #homepage) '; Document.body.setHomePage (' http://www.jb51.net '); The else if (Window.sidebar) {if (Window.netscape) {try {netscape.security.PrivilegeManager.enablePrivilege ("Univer Salxpconnect "); catch (E) {alert ("This action is aviod by your browser,if you want to enable,please enter About:config in your Addre SS Line,and Change the value of Signed.applets.codebase_principal_support to true "); } var prefs = components.classes[' @mozilla. Org/preferences-service;1 '].getservice (components. Interfaces.nsiprefbranch); Prefs.setcharpref (' browser.startup.homepage ', ' http://www.jb51.net '); } </script> <input type= "button" value= "Set home page" onclick= "setHomePage ();"/></textarea>
[Ctrl + A All SELECT Note: If the need to introduce external JS need to refresh to perform]