// JavaScript Document
/* Open new Windows */
function popup(URLStr,width, height)
{
  var popUpWin=0;
  var left = (screen.width/2) - width/2;
  var top = (screen.height/2) - height/2;

  if(popUpWin)
  {
    if(!popUpWin.closed) popUpWin.close();
  }
  popUpWin = open(URLStr, 'popUpWin', 'toolbar=no,location=no,directories=no,status=no,menub ar=no,scrollbars=yes,resizable=no,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
}
///
function onlynum(field)
{
streng = field.value;
newstreng = '';
   for (i = 0; i < streng.length; i++)
   {
      thischar = field.value.substring(i, i+1)
      if (thischar == '1' || thischar == '2' || thischar == '3' || thischar == '4' || thischar == '5' || thischar == '6' || thischar == '7' || thischar == '8' || thischar == '9' || thischar == '0')
         newstreng = newstreng + streng.substring(i, i+1);
   }
field.value = newstreng;
}
///
function next_focust(len, num, obj)
	{
		if (len == num)
		{
			document.getElementById(obj).focus();
			return true
		}else{
			return false
		}
	}
//refresh Ë¹éÒ·Õè¼èÒ¹ÁÒ áÅéÇ»Ô´Ë¹éÒ popup
function RELOAD(xtime)
{
   window.opener.location.reload();
   setTimeout("self.close()",xtime);
}

/* function close windows auto */
function AUTO_CLOSE(xtime)
{
   setTimeout("self.close()",xtime);
}