var flashVersion=false;
var nn=(navigator.appName.charAt(0)=="N" && navigator.userAgent.indexOf("Safari") == -1) || false;
var n6=(document.getElementById && nn) || false;
var ie=(document.all && !nn) || false;
var safari=(navigator.userAgent.indexOf("Safari")!=-1) || false;
var mac=(navigator.userAgent.indexOf("Mac")!=-1) || false;
var ver=""+navigator.appVersion;
var fno=ver.indexOf(" ");
var macChecked=0;
ver=eval(ver.substring(0,fno));
var macIE5=(mac && navigator.userAgent.indexOf("MSIE 5")!=-1) || false;

if (ie && !mac){
  var flashVersion=new ActiveXObject("ShockwaveFlash.ShockwaveFlash").FlashVersion();
  flashVersion=Math.floor(flashVersion / 0x10000);
}

if (!flashVersion){
  if (nn && !document.plugins &&!safari) 
    flashVersion=false;
  else if ((nn || n6 || safari || macIE5) && navigator.plugins) 
    flashVersion = navigator.plugins["Shockwave Flash"].description.charAt(16);
  else 
    flashVersion=false;
}

if (ie && mac && !macIE5){
  window.onload=chkMac;
}

function chkMac(){
  if (window["sample"])
    flashVersion = ((window["sample"].FlashVersion() & 0xffff0000) >> 16);
  macChecked=1;
  (window["sample"]);
  result();
}

function result() {
  if (mac && ie && !macIE5 && macChecked==0) return;
  if (!flashVersion) location.replace("download.html");
  else if (flashVersion<=7) location.replace("download.html");
  else location.replace("flash8.html");
}

function popupWindow(url) {
  window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=300,height=300,screenX=50,screenY=150,top=50,left=150')
}

function shop(theURL){
window.open(theURL,"","toolbar=yes,menubar=yes,location=yes,status=yes,scrollbars=yes,resizable=yes,width=800,height=800");
}
