function flashCode(path)
	{
	var html;
	
	html='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0" width="935" height="122" id="header" align="middle">';
	html+='  <param name="allowScriptAccess" value="sameDomain">';
	html+='  <param name="allowFullScreen" value="false">';
	html+='  <param name="movie" value="'+path+'header.swf">';
	html+='  <param name="quality" value="high">';
	html+='  <param name="bgcolor" value="#ffffff">';
	html+='  <embed src="'+path+'header.swf" quality="high" bgcolor="#ffffff" width="935" height="122" name="header" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>';
	html+='</object>';

	document.write(html);
	}

function flashCode2(path)
	{
	var html;
	
    html='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0" width="801" height="442">';
    html+='  <param name="movie" value="'+path+'intro.swf">';
    html+='  <param name="quality" value="high">';
    html+='  <embed src="'+path+'intro.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="801" height="442"></embed>';
    html+='</object>';

	document.write(html);
	}


function flashCode3(path,vars)
	{
	var html, url, val, i, arr;
	
	url=window.location.search.substr(1);
	if (url.length)
		{
		arr=url.split("&");
		for(i=0;i<arr.length;i++)
			{
			val=arr[i];
			val=val.split("=");
			switch(val[0])
				{
				case "seldoc":
					vars+="&docid="+val[1];
					break;
				case "content":
					vars+="&content="+val[1];
					break;
				}
			}
		}

	html='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0" id="gallery" width="935" height="280" align="middle">';
    html+='  <param name="allowScriptAccess" value="sameDomain">';
    html+='  <param name="movie" value="'+path+'gallery.swf">';
    html+='  <param name="quality" value="high">';
    html+='  <param name="bgcolor" value="#ffffff">';
    html+='  <param name="FlashVars" value="'+vars+'">';
    html+='  <embed src="'+path+'gallery.swf" FlashVars="'+vars+'" quality="high" bgcolor="#ffffff" width="935" height="280" swLiveConnect=true name="photos/gallery" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>';
    html+='</object>';
	
	document.write(html);
	}


function calculatePosition(obj) 
	{   
	var offsetLeft = 0, offsetTop = 0;

	if (obj.offsetParent)
		{
		offsetLeft = obj.offsetLeft;
		offsetTop = obj.offsetTop;
		while (obj = obj.offsetParent)
			{
			offsetLeft += obj.offsetLeft;
			offsetTop += obj.offsetTop;
			}
		}
		
	return [offsetLeft,offsetTop];
	}
	
	
function highlightItem(srcObj,state)
	{
	var pos, obj=document.getElementById("infoLabel");
	var offY = 0;
	
	if (srcObj.parentNode.tagName=="LI" && navigator.appVersion.indexOf("MSIE") != -1) offY=-1;
	if (!obj) return;
	if (state)
		{
		pos=calculatePosition(srcObj);
		obj.style.left=(pos[0]-obj.offsetWidth-15)+"px";
		obj.style.top=(pos[1]+offY)+"px";
		obj.style.visibility="visible";
		}
	else
		obj.style.visibility="hidden";
	}
