<!--
//window.name = 'main';

function close_window(popup) {
	if (top.pgname) {
		if (top.pgname.closed) {
			return false;
		} else {
    		if (popup == "nav") {
    			// hack--reset the window object
    			top.navWin = window.open('','navWin');
    			top.navWin.close();
    		} else if (popup == "content") {
    			// hack--reset the window object
    			top.contentWin = window.open('','contentWin');
    			top.contentWin.close();
    		}	
    		return false;
		}
	}
}

function open_navPop(page,pgname,r,w,h,t,l,s) {		
	if (s == '') {
		s = 1;
	}
	//if (getFlashVersion() >= 5) {
		//l = (screen.availWidth -w)/2;
		//t = (screen.availHeight -h)/2;
	//} else {
		//alert('Flash is needed to view this site.')
	//}

    top.pgname = window.open(page,pgname,'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=' + s + ',resizable=' + r + ',personalbar=0,width=' + w + ',height=' + h + ',top=' + t + ',left=' + l + ',screenY=' + t + ',screenX=' + l );
    top.pgname.focus();
    if (!top.pgname.opener) {
    	top.pgname.opener = self;
    	return false;
    }
}


// debug
function debug() {
    var output = '';

    if (top.pgname) {
        output = 'pop-up has been opened at least once by this window';
        if (top.pgname.closed) output += '\npop-up is closed';
        else {
            output += '\npop-up is currently open' +
                      '\nname: ' + top.pgname.name +
                      '\nopener: ' + top.pgname.opener.name +
                      '\nlocation: ' + top.pgname.location.href +
                      '\ntitle: ' + top.pgname.document.title;
        }
    }
    else output = 'pop-up has not yet been opened by this window';

    return output;
}

//-->
