// JavaScript Document

window.addEvent('domready', Table01_init);


// prevent javascript error before the content has loaded
;

function Table01_init() 
{
	Table01_show();
	window.onresize=function(){ Table01_show(); }  
}

function Table01_show()
{
	var TB_WIDTH = 0;
	var TB_HEIGHT = 0;
	var GETHEIGHT = 0;
	var GETWIDTH = 0;
	TB_WIDTH = parseInt($("Table_01").getStyle("width").replace(/px/,""))
	TB_HEIGHT = parseInt($("Table_01").getStyle("height").replace(/px/,""))
	if (is_opera)
	{
		GETHEIGHT = document.documentElement.clientHeight;
		GETWIDTH = document.documentElement.clientWidth;
	}
	else
	{
		GETHEIGHT = window.getHeight();
		GETWIDTH = window.getWidth();
	}
	


	//window.alert("width:" + TB_WIDTH + ",height:"+TB_HEIGHT+",windowwidth:"+GETWIDTH+",windowheight:"+GETHEIGHT );
	NEWWIDTH = window.getScrollLeft() + ((GETWIDTH - TB_WIDTH)/2);
	NEWHEIGHT = window.getScrollTop() + ((GETHEIGHT - TB_HEIGHT)/2)-0;
	
	if (NEWHEIGHT >0) {
		$("Table_01").setStyles({top: NEWHEIGHT+'px'});
	}
	if (NEWWIDTH >0) {
		$("Table_01").setStyles({left: NEWWIDTH+'px'});
	}
	
	//$("Table_01").setStyles({left: '100px', right: '100px'});
}
