/* This function is used for greyed background and to show popup*/
function ShowPopUp(url,width, height,name)
{ 
	if(!width) width = 450;
	if(!height) height = 550;
	if(!name) name = null;
	
	if(name=='image')
	{
		wWidth = width+20;
		wheight = height+45;
	}
	if(name=='flv')
	{
		wWidth = width+20;
		wheight = height+35;
	}
	else
	{
		wWidth = width + 40;
		//wheight = height + 95;
		wheight = height + 80;
	}
	
		//url='http://localhost/mediaplayer/mediaplayer.php?url='+url+'&size='+width+'&height='+height;
	
	 url='http://www.one-world-trading.com/mediaplayer/mediaplayer.php?url='+url+'&size='+width+'&height='+height;
	
	
	//var pagesize = TB_getPageSize();	
	//Styles for popup
	y =10; //(pagesize[1]-height)/2;
	x =10;//(pagesize[0]-width)/2;
	window.open(url,name,'width='+wWidth+',height='+wheight+',resizable=no,scrollbars=no,left='+x+',top='+y+',screenX='+x+',screenY='+y+',status=yes');

}


function TB_getPageSize(){
	var de = document.documentElement;
	var w = window.innerWidth || self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth;
	var h = window.innerHeight || self.innerHeight || (de&&de.clientHeight) || document.body.clientHeight
	arrayPageSize = new Array(w,h) 
	return arrayPageSize;
}

