function useSwf(swfUrl,swfW,swfH,wmode,swfID)
{
	if(swfID){idStr='id='+swfID}else{idStr=''}
	if(wmode){
		wmodeStr1='<param name="wmode" value="transparent" />'
		wmodeStr2='wmode=transparent'
	} else {
		wmodeStr1='';
		wmodeStr2='';
	}
	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" '+idStr+' width='+swfW+' height='+swfH+'>')
	document.write('<param name="movie" value="'+swfUrl+'" />')
        document.write('<param name="allowScriptAccess" value="always" />')
	document.write('<param name="menu" value="false" />')
	document.write('<param name="quality" value="best" />')
	document.write(wmodeStr1)
	document.write('<embed src="'+swfUrl+'" width='+swfW+' height='+swfH+' '+idStr+' '+wmodeStr2+' menu=false quality=best type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />')
	document.write('</object>')
}
var menuTopMargin = 80;
var menuSpeed = 5;
var timerSpeed = 200;
var timer;
var heightLimit = 0;
var offset = 260

function checkMenu() {
	if(document.body.offsetHeight > heightLimit) {
		var reTimer = timerSpeed;
		var startPoint = parseInt(document.all.sMenu.style.top,10);
		var endPoint = document.body.scrollTop + offset;
		
		endPoint = (menuTopMargin <= endPoint ) ? endPoint - menuTopMargin + (offset-80) : offset;
		if(startPoint != endPoint) {
			moveAmount = Math.ceil(Math.abs(endPoint - startPoint) / 15);
			document.all.sMenu.style.top = parseInt(document.all.sMenu.style.top,10) + ((endPoint<startPoint) ? -moveAmount : moveAmount);
			reTimer = menuSpeed;
		}
	} else document.all.sMenu.style.top = 0;
	timer = setTimeout("checkMenu();",reTimer);
}

function initsMenu(val) {
	if(document.body.offsetHeight > heightLimit) document.all.sMenu.style.top = document.body.scrollTop + offset;
	menuTopMargin = val
	checkMenu();
}