//BROWSER DETECT
var verStr=navigator.appVersion;
var app=navigator.appName;
var verSub=navigator.vendorSub;
var version=parseFloat(verStr);

var user=navigator.userAgent;
if(user.indexOf("Mac") >= 0){
 platformname="Mac";
}else{
 platformname="PC";
}
if(user.indexOf("Opera") >= 0){
 if(version < 7){
  var browsertype="archaic";
 }else{
  var browsertype="modern";
 }
 browserid="Opera";
 strlocation = user.indexOf("Opera");
 strlocation1 = strlocation+6;
 strlocation2 = strlocation+8;
 strlocation3 = strlocation+9;
}else if(user.indexOf("Safari") >= 0){
 var browsertype="modern";
 browserid="Safari";
 strlocation = user.indexOf("Safari");
 strlocation1 = strlocation+7;
 strlocation2 = strlocation+8;
 strlocation3 = strlocation+9;
}else if((user.indexOf("Gecko") >= 0)&(user.indexOf("Netscape") < 0)){
 var browsertype="modern";
 browserid="Netscape";
 strlocation = user.indexOf("Gecko");
 strlocation1 = strlocation-5;
 strlocation2 = strlocation-3;
 strlocation3 = strlocation-2;
}else{
 if(app.indexOf("Netscape") >= 0){
  if(version < 5){
   var browsertype="archaic";
   strlocation = user.indexOf("Mozilla");
   strlocation1 = strlocation+8;
   strlocation2 = strlocation+10;
   strlocation3 = strlocation+11;
  }else{
   var browsertype="modern";
   var netscapeMajorVersion = verSub.charAt(0);
   strlocation = user.indexOf("Netscape");
   strlocation1 = strlocation+9;
   strlocation2 = strlocation+11;
   strlocation3 = strlocation+12;
  }
  browserid="Netscape";
 }else if(app.indexOf("Microsoft Internet Explorer") >= 0){
  if(verStr.indexOf("MSIE 4") >= 0){
   var browsertype="archaic";
  }else{
   var browsertype="modern";
  }
  browserid="IE";
  strlocation = user.indexOf("MSIE");
  strlocation1 = strlocation+5;
  strlocation2 = strlocation+7;
  strlocation3 = strlocation+8;
 }else{
  browserid="Netscape";
  strlocation = user.indexOf("Mozilla");
  strlocation1 = strlocation+9;
  strlocation2 = strlocation+10;
  strlocation3 = strlocation+11;
 }
}
var version1 = user.charAt(strlocation1);
var version2 = user.charAt(strlocation2);
var version3 = user.charAt(strlocation3);
if((version3.indexOf(";") >= 0)||(version3.indexOf(")") >= 0)){
 var version3 = "0";
}
var majorversion = version1;
var minorversion = version2+version3;
var fullversion = version1+"."+version2+version3;







//bookmark page
function bookmarkpage(){

if(platformname!="PC"){
 window.alert("Press Apple+D to bookmark this page.")
  }else{
   if(browserid!="IE"){
    if(browserid!="Opera"){
      window.alert("Press Ctrl+D to bookmark this page.")
    }else{
      window.alert("Press Ctrl+T to bookmark this page.")
    }
   }else{
     window.external.AddFavorite(location.href, document.title)
   }
  }

}
