var arImages = new Array();

function preloadArray(arNames) 
{ 
	for (var x in arNames) 
	{
		if (typeof(arImages [x]) == "string") {
  			arImages[x] = new Image();
  			arImages[x].src = arNames[x];
		}
	}
}

function preloadList()
{
	var temp = preloadList.arguments; 
	
	preloadArray(temp);
}

function openPopUp(myurl)
{
	window.open(myurl,"newwindow","height=415,width=475,toolbar=no,resizable=yes,status=yes,location=no,menubar=no,scrollbars=yes");
}

function showDiabetesTerm(theTerm)
{
	if (window.screen)
	{
		var chasm = screen.availWidth;
		var mount = screen.availHeight;

		var w = 475;
		var h = 400;
								
		winprops = 'width=' + w + ',height=' + h + ',left=' + ((chasm - w - 10) * .5) + ',top=' + ((mount - h - 30) * .5) + ',toolbar=no,resizable=no,status=yes,location=no,menubar=no,scrollbars=yes';

		oHTMLWin = window.open("http://www.diabetes.org/diabetesterm.jsp?term=" + escape(theTerm) + "&requestingURL=" + escape(jspvalURL),'DiabetesTerm',winprops);
		oHTMLWin.window.focus();
	}			
}

function genericPopup(width, height, url)
{
	var params = "\'width=" + width + ",height=" + height + ",location=no,toolbar=no,resizable=yes,menubar=yes,scrollbars=yes'";
	window.open(url, 'newwindow', eval(params));
}

