var bname = navigator.appName;
var isIE=false;
if (bname == "Microsoft Internet Explorer")
{
    isIE=false;
}





var currentPage="";


function displayFlash(flashfile, flashid, flashwidth, flashheight, flashvars, align, salign, minWidth, minHeight, bgcolor) {

  
  document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="'+flashwidth+'" height="'+flashheight+'" id="'+flashid+'" align="'+align+'" VIEWASTEXT>\n');
  document.write('<param name="allowScriptAccess" value="sameDomain" />\n');
  document.write('<param name="movie" value="'+flashfile+'" />\n');
  document.write('<param name="quality" value="high" />\n');
  document.write('<param name="scale" value="noscale" />\n');
  document.write('<param name="salign" value="'+salign+'" />\n');
  document.write('<param name="wmode" value="transparent" />\n');
  document.write('<param name="bgcolor" value="'+bgcolor+'" />\n');
  document.write('<embed src="'+flashfile+'" wmode="transparent" quality="high" scale="noscale" salign="'+salign+'" bgcolor="'+bgcolor+'" width="'+flashwidth+'" height="'+flashheight+'" name="'+flashid+'" align="'+align+'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');
  document.write('</object>\n');
 
}
function loadFlashPage(p) {
    
    if (isIE) {
        //alert("IS IE");
        document.getElementById("historyframe").src="showpage.html?page="+p;
    } else {
        window.location="#"+p;
        setPage(p);
    }
}


function setPage(page) {
    currentPage=page;
	if (window.document.main) {
		window.document.main.SetVariable("page_action", page);
	} else {
		//alert("no movie to go back!"+window.document.main);
	}
}
function checkNavURL() {
    var fullurl=""+window.location;
    var page=fullurl.split("#")[1];
    if (currentPage!=page) {
        setPage(page);
    }
}
function reloadPage() {
	setPage(parent.historyframe.getPage());
}

if (!isIE) {
    setInterval("checkNavURL()", 200);
}

function AddFlashContent(flashfile) {
  displayFlash("flash/"+flashfile+".swf", 'flashContent', 990, 550, '', 'middle', 'lt', 990, 550, '#ffffff')
/*
  if (AC_FL_RunContent == 0) {
		alert("This page requires AC_RunActiveContent.js.");
	} else {
		AC_FL_RunContent(
			'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0',
			'width', '990',
			'height', '550',
			'src', "flash/"+flashfile+".swf",
			'quality', 'high',
			'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
			'align', 'middle',
			'play', 'true',
			'loop', 'true',
			'scale', 'noscale',
			'wmode', 'transparent',
			'devicefont', 'false',
			'id', 'location',
			'bgcolor', '#9fc964',
			'name', 'location',
			'menu', 'true',
			'allowFullScreen', 'false',
			'allowScriptAccess','sameDomain',
			'movie', flashfile,
			'salign', 'lt'
			); //end AC code
	}
*/
	}