﻿function getObj(name)
{
	if (document.all)
		{
			this.obj = document.all[name];
			return this.obj;
		}
	else if (document.getElementById)
		{
			this.obj = document.getElementById(name);
			return this.obj;
		}
	else if (document.layers)
		{
			this.obj = document.layers[name];
			return this.obj;
		}
}

function openNewWindow(URLtoOpen,windowName)
{
    windowFeatures ="channelmode=0,dependent=0,directories=0,fullscreen=0,location=0,menubar=0,resizable=yes,scrollbars=yes,status=yes,toolbar=yes";
    var test = "'"; 
    var width = "700px";
    var height = "700px";
    winLeft = (screen.width-width)/2; 
    winTop = (screen.height-(height+110))/2; 
    myWin= open(URLtoOpen,windowName,"with=" + width + "height=" + height + ",left=" + winLeft + ",top=" + winTop + test + windowFeatures + test);
    
    if (window.focus) {myWin.focus()}
	return false;

    myWin.document.open();
    myWin.document.close();
}

function golink(link) {
    window.top.location = link;
}

