// JavaScript Document

function subwindow(url, width, height, winname, scrollbars, resizable) {
	if(winname == undefined)
		winname = "thegeneral";
    if(scrollbars == undefined)
		scrollbars = 0;
	if(resizable == undefined)
		resizable = 0;
	
//    var left=(screen.availWidth-width)/2;
//    var top=(screen.availHeight-height)/2;
    var popup = window.open(url, winname, "scrollbars="+scrollbars+",resizable="+resizable+",status=0,location=0,width="+width+",height="+height/*+",screenX="+left+",screenY="+top*/);
//    popup.moveTo(left,top)
    popup.focus();
}

function popup_verisign()
{
	subwindow("https://seal.verisign.com/splash?form_file=fdf/splash.fdf&dn=WWW.THEGENERAL.COM&lang=en", 530, 430);
}

function popup_general(location)
{
	subwindow(location, 630, 430, 'generalpopup', 'yes', 'yes');
}

function popup_coinfo(location)
{
	subwindow(location, 700, 430, 'generalpopup', 'yes', 'yes');
}

function popup_emailus(location)
{
	subwindow(location, 800, 650, 'generalpopup', 'yes', 'yes');
}
function popup_help(location)
{
	subwindow(location, 730, 330, 'helpText', 'yes', 'yes');
}

function confirmRedirect(location) {
	var answer = confirm("You are about to leave TheGeneral.com website and are being re-directed to Permanent General, parent company of TheGeneral.")
	if (answer){
		window.location = location;
	}
	
}
