function detectFlash() {  
  if (navigator.plugins) {
    if (navigator.plugins["Shockwave Flash 2.0"]
        || navigator.plugins["Shockwave Flash"]) {
      var isVersion2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
      var flashDescription = navigator.plugins["Shockwave Flash" + isVersion2].description;
      var flashVersion = parseInt(flashDescription.substring(16));
      flash2Installed = flashVersion == 2;    
      flash3Installed = flashVersion == 3;
      flash4Installed = flashVersion == 4;
      flash5Installed = flashVersion == 5;
      flash6Installed = flashVersion == 6;
      flash7Installed = flashVersion == 7;
      flash8Installed = flashVersion == 8;
      flash9Installed = flashVersion >= 9;
    }
  }
  for (var i = 2; i <= maxVersion; i++) {  
    if (eval("flash" + i + "Installed") == true) actualVersion = i;
  }
  if(navigator.userAgent.indexOf("WebTV") != -1) actualVersion = 4;  
  if (actualVersion >= requiredVersion) {
    if (useRedirect) {
      if(jsVersion > 1.0) {
        window.location.replace(flashPage);  
      } else {
        window.location = flashPage;
      }
    }
    hasRightVersion = true;                
  } else {  
    if (useRedirect) {
      if(jsVersion > 1.0) {
        window.location.replace((actualVersion >= 2) ? upgradePage : noFlashPage);
      } else {
        window.location = (actualVersion >= 2) ? upgradePage : noFlashPage;
      }
    }
  }

  if(!hasRightVersion) {
	document.write('<style type="text/css" media="screen">#galleryCont {background-color:#FFFFFF;background-image:url('+url+'images/misc/flash-plugin.gif);background-position:center;background-repeat:no-repeat;}#galleryCont a {height:100%;width:100%;margin:auto auto;display:block;}</style>'); 
  }
}
detectFlash();

var portfolioFlash;
var theTop = 0;
var old = theTop;
var holder = "galleryCont";
	//
	function moveobject() {
		if (window.innerHeight) {
			pos = window.pageYOffset;
		} else if (document.documentElement && document.documentElement.scrollTop) {
			pos = document.documentElement.scrollTop;
		} else if (document.body) 	{
			pos = document.body.scrollTop;
		}
		//
		if (pos == old) {
			if (document.layers) {
				document.all.holder.top = pos;
			} else 	if (document.all) {
				document.all.galleryCont.style.top = pos;
			} else 	if (!document.all && document.getElementById) {
				document.getElementById(holder).style.top = pos+"px";
			}
		}
		old = pos;
		temp = setTimeout('moveobject()', 200);
}