This example also uses conditional comments to gracefully hide the link from downlevel browsers.
The style block goes in the page <HEAD>:
<style> <!-- .homepage {behavior:url(#_IE_)} --> </style>
This code can be placed anywhere in the page body:
<!--#if IE 5#> <U><SPAN STYLE='color:blue;cursor:hand;' CLASS=homepage ONCLICK='this. setHomePage(window.location);'> Make this your home page</SPAN></U> <!#endif#-->
You can also change the user's home page to a page other than the current page by replacing window.location in the above example with a specific URL.
For example:ONCLICK="this.setHomePage('http://www.myhome.com')"To prevent "slamming," the browser first asks the user if he or she wants to change their home page rather than setting it automatically.