var vrootrousseau = 'http://www.rousseaumetal.com/';
var vrootauto = 'http://www.rousseau-automotive.com/';
var vrootrousseauprod = 'http://www.rousseaumetal.com/';

function OpenWindow(vurl,vname)
{
	vheight = screen.availHeight - 100;
	vwidth = screen.availWidth - 10;

	vheight = document.all?document.body.clientHeight:innerHeight;

	vheight = vheight + 10;
	vwidth = screen.availWidth - 10;

	mywindow = window.open(vurl,vname,'height='+vheight+',width='+vwidth+',left=0,top=0,status=yes,menubar=yes,scrollbars=yes,location=1,resizable=yes,toolbar=yes')

	if(mywindow)
		mywindow.focus();
}

function OpenURL(vroot,vpage,vname)
{
	vheight = screen.availHeight - 100;
	vwidth = screen.availWidth - 10;

	//vheight = document.all?document.body.clientHeight:innerHeight;

	vheight = vheight + 10;
	vwidth = screen.availWidth - 10;

	var vtheurl = vroot + vpage;

	mywindow = window.open(vtheurl,vname,'height='+vheight+',width='+vwidth+',left=0,top=0,status=yes,menubar=yes,scrollbars=yes,location=1,resizable=yes,toolbar=yes')

	if(mywindow)
		mywindow.focus();
}

function OpenURLParam(vroot,vpage,vname,vparam)
{
	vheight = screen.availHeight - 100;
	vwidth = screen.availWidth - 10;

	//vheight = document.all?document.body.clientHeight:innerHeight;

	vheight = vheight + 10;
	vwidth = screen.availWidth - 10;

	var vtheurl = vroot + vpage;

	mywindow = window.open(vtheurl,vname,vparam)

	if(mywindow)
		mywindow.focus();
}

function resize_product()
{
	vsearchheight = document.getElementById('td_search').offsetHeight;
	vappheight = document.getElementById('td_app').offsetHeight;
	vproductdetail = document.getElementById('trproductdetail').offsetHeight;
	vmodelheight = document.getElementById('div_model').offsetHeight;
	vleftsection = parseInt(vappheight) + parseInt(vsearchheight);
	vrightsection = parseInt(vmodelheight) + vproductdetail + 30;
	vsearchheight2 = document.getElementById('td_search2').offsetHeight;
	vsearchacc = document.getElementById('td_acc').offsetHeight;

	if(parseInt(vleftsection)>parseInt(vrightsection))
	{
		var vtempheight = parseInt(vappheight) + parseInt(vsearchheight) - 30 - parseInt(vproductdetail);
		document.getElementById('div_model').style.height = vtempheight;
	}

	document.getElementById('div_acc').style.height = (parseInt(vsearchheight) - 30);

	if(parseInt(vsearchheight2)<parseInt(vsearchacc))
		document.getElementById('td_search2').style.height = vsearchacc;
}
