// JavaScript Document
function popup(mylink, windowname)
{
if (! window.focus)return true;
var href;
if (typeof(mylink) == 'string')
   href=mylink;
else
   href=mylink.href;
window.open(href, windowname, 'width=820,height=680,scrollbars=yes');
return false;
}

function popupSayings(mylink, windowname)
{
if (! window.focus)return true;
var href;
if (typeof(mylink) == 'string')
   href=mylink;
else
   href=mylink.href;
window.open(href, windowname, 'width=350,height=320,scrollbars=yes');
return false;
}

function submitForm(param,index) {
	//param list is encoded as <url>&<location> in the optionlist
	//url is the complete path of where to go
	//location is a flag of whether to open a new window or use the same
	if (index > 0 )
		{
		var paramList = param.split("\&");
		var oidStr = paramList[0];
		var location = paramList[1];
		var myhost = "http://" + window.top.location.hostname;
		var myport = window.top.location.port;
		if (myport != "" && myport != "80") {
			myhost += ":" + myport;
		}
		if (location == "") {
			window.top.location = myhost + oidStr;
		} else {
			PopUpWindow(oidStr, "externalSiteWindown", 650, 650); 
		}
	}
}  
function PopUpWindow(url, windowName, width, height) {
	window.open(url, windowName, "top=30, width=" + width + ",height=" + height + ", menubar, scrollbars, toolbar, resizable, status, location, directories");
}

