//相对固定浮动层
//float(objID, Width, Height, Top, Bottom, Left, Right)
function float(objID, Width, Height, Top, Bottom, Left, Right){

	document.getElementById(objID).style.width = Width;
	document.getElementById(objID).style.height = Height;
	document.getElementById(objID).style.position = "absolute";
	document.getElementById(objID).style.textAlign = "center";
	document.getElementById(objID).style.zIndex = 99;
		if (Top != 0 && Bottom == 0) {
			document.getElementById(objID).style.posTop = document.documentElement.scrollTop + Top;
		}		
		if (Top == 0 && Bottom != 0) {
			document.getElementById(objID).style.posTop = document.documentElement.scrollTop + document.documentElement.clientHeight - Height - Bottom;			
		}
		
		if (Right != 0 && Left == 0) {
			document.getElementById(objID).style.posLeft = document.documentElement.clientWidth - Width - Right;
		}
		if (Right == 0 && Left != 0) {
			document.getElementById(objID).style.posLeft = Left;
		}		
		setTimeout("float('"+objID+"',"+Width+","+Height+","+Top+","+Bottom+","+Left+","+Right+");",30);
}
