// JavaScript Document

//操作警告
function ChkAct(msg)
{
  if(!confirm(msg)) return false;
}

//跳转
function gourl(url)
{
	this.location.href = url;
}

//返回对象
function getObj(objID){
	return document.getElementById(objID);
}


//设置元素内容
function SetContent(objID,Txt)
{
	getObj(objID).innerHTML = Txt;
}

//
function ShowHide(oID){
	var obj = getObj(oID);
	if(obj.style.display == "none")
	{
		obj.style.display = "";
	}else{
		obj.style.display = "none";
	}
}

function SetClassName(obj,sClass){
	obj.className = sClass;
}

function gamePlay(){
	openwindow("http://218.206.83.85/lft/index.jsp","",500,320,true);
}

function openwindow( url, winName, theWidth, theHeight, scrolls ) {
	xposition=0; yposition=0;
	if ((parseInt(navigator.appVersion) >= 4 )){
		xposition = (screen.width - theWidth) / 2;
		yposition = (screen.height - theHeight) / 2;
	}
	var theproperty= "width=" + theWidth + "," ;
	theproperty+= "height=" + theHeight + "," ;
	theproperty+= "location=0," ;
	theproperty+= "menubar=0,";
	theproperty+= "resizable=0,";
	if(scrolls)
		theproperty+= "scrollbars=" + scrolls + ",";
	else
		theproperty+= "scrollbars=0,";	
	theproperty+= "status=1," ;
	theproperty+= "titlebar=0,";
	theproperty+= "toolbar=0,";
	theproperty+= "hotkeys=0,";
	theproperty+= "screenx=" + xposition + ","; //Netscape
	theproperty+= "screeny=" + yposition + ","; //Netscape
	theproperty+= "left=" + xposition + ","; //IE
	theproperty+= "top=" + yposition; //IE 
	return( window.open( url,winName,theproperty ) );
}