function addfav() {

PxUA=(navigator.userAgent);
locMSIE=PxUA.indexOf("MSIE");
locNS=PxUA.indexOf("Netscape");
locOpera=PxUA.indexOf("Opera");
locFirefox=PxUA.indexOf("Firefox");
locMozilla=PxUA.indexOf("Mozilla");
locGecko=PxUA.indexOf("Gecko");

if( window.sidebar && window.sidebar.addPanel ) {
    //Gecko (Netscape 6 etc.) - add to Sidebar
    window.sidebar.addPanel( "Computer Business Review", "http://www.cbronline.com/home.asp", '' );
window.location="http://www.cbronline.com/home.asp";
}

 else if( window.external && ( navigator.platform == 'Win32' ||
      ( window.ScriptEngine && ScriptEngine().indexOf('InScript') + 1 ) ) ) {
    //IE Win32 or iCab - checking for AddFavorite produces errors for no
    //good reason, so I use a platform and browser detect.
    //adds the current page page as a favourite; if this is unwanted,
    //simply write the desired page in here instead of 'location.href'
    window.external.AddFavorite( "http://www.cbronline.com/home.asp", "Computer Business Review" );
window.location="http://www.cbronline.com/home.asp";

} else if( document.layers ) {
    //NS4 & Escape - tell them how to add a bookmark quickly (adds current page,
    //not target page)
    window.alert( 'Please click OK then press Ctrl+D to create a bookmark' );
} else {
    //other browsers - tell them to add a bookmark (adds current page, not target page)
    window.alert( 'Please use your browser\'s bookmarking facility to create a bookmark' );
}
return false;
}

/* Excert from Paul Snowdons switcher
http://www.alistpart.com/articles/alternate
*/

function setActiveStyleSheet(title) {
   var i, a, main;
   for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
     if(a.getAttribute("rel").indexOf("style") != -1
        && a.getAttribute("title")) {
       a.disabled = true;
       if(a.getAttribute("title") == title) a.disabled = false;
     }
   }
}
