/*************************************************************************
  This code is from Dynamic Web Coding at http://www.dyn-web.com/
  Copyright 2003 by Sharon Paine 
  See Terms of Use at http://www.dyn-web.com/bus/terms.html
  regarding conditions under which you may use this code.
  This notice must be retained in the code as is!
*************************************************************************/

var emergency = '<div class="tp1">24/7 Crisis Contacts</div>';

// leave in page for way to customize layout of tooltip 
// and avoid errors if onmouseovers/outs before page completely loaded
function doTooltip(e, msg) {
  if ( typeof Tooltip == "undefined" || !Tooltip.ready ) return;
  Tooltip.show(e, msg);
}

function hideTip() {
  if ( typeof Tooltip == "undefined" || !Tooltip.ready ) return;
  Tooltip.hide();
}
	
// preload images that will be displayed in tooltip  
// put images to preload in this array
var preload_list = new Array("dot-com-btn.gif", "sm-duck.gif");
var path_to_images = "images/";

if (document.images) {
	var image_list = new Array();
	for (var preload_counter=0; preload_counter<preload_list.length; preload_counter++) {
  	image_list[preload_counter] = new Image(); 
		image_list[preload_counter].src = path_to_images + preload_list[preload_counter];	
  }
}



with(menuStyle=new mm_style()){
onbgcolor="#ffffff";
oncolor="#2D3688";
offbgcolor="#2D3688";
offcolor="#ffffff";
pagebgcolor="#ffffff";
pagecolor="#2D3688";
bordercolor="#2D3688";
//borderstyle="solid";
borderwidth=1;
//separatorcolor="#2D729D";
//separatorsize="1";
padding=5;
fontsize="75%";
fontstyle="normal";
fontfamily="Tahoma, Arial, Helvetica";
headercolor="#000000";
headerbgcolor="#ffffff";
//subimage="arrow.gif";
//subimagepadding="2";
overfilter="Alpha(opacity=90);";
itemwidth=152;
//overfilter="Fade(duration=0.2);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
//outfilter="randomdissolve(duration=0.3)";

}

with(menuTopStyle=new mm_style()){
//separatorcolor="#2D3688";
separatorsize=18;
overfilter="Alpha(opacity=90);";
itemwidth=152;
onbgcolor="#2D3688";
oncolor="#ffffff";
offbgcolor="#ffffff";
offcolor="#2D3688";
pagebgcolor="#2D3688";
pagecolor="#ffffff";
//bordercolor="#2D3688";
//borderstyle="solid";
//borderwidth=1;
separatorcolor="#ffffff";
//separatorsize="1";
padding=5;
fontsize="12px";
fontstyle="normal";
fontweight="bold";
fontfamily="Tahoma, Arial, Helvetica";
headercolor="#000000";
headerbgcolor="#ffffff";
//subimage="arrow.gif";
//subimagepadding="2";
overfilter="Alpha(opacity=90);";
itemwidth=136;
//overfilter="Fade(duration=0.2);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
//outfilter="randomdissolve(duration=0.3)";
}

function drawTopNav() {
document.write(
	'<table border="0" cellpadding="0" cellspacing="0">' + 
	'<tr>' +
	'	<td><a href="' + linkHome + '" onmouseover="img_act(\'hhome\');" onmouseout="img_inact(\'hhome\');"><img src="/images/rollovers/hhome_off.gif" width="47" height="25" border="0" alt="home" name="hhome"></a></td>' +
	'	<td><a href="' + linkAbout + '" onmouseover="img_act(\'habout\');" onmouseout="img_inact(\'habout\');"><img src="/images/rollovers/habout_off.gif" width="104" height="25" border="0" alt="home" name="habout"></a></td>' +
	'<td><a href="' + linkSitemap + '" onmouseover="img_act(\'hsitemap\');" onmouseout="img_inact(\'hsitemap\');"><img src="/images/rollovers/hsitemap_off.gif" width="67" height="25" border="0" alt="site map" name="hsitemap"></a></td>' +
	'<td><a href="' + linkPrivacy + '" onmouseover="img_act(\'hprivacy\');" onmouseout="img_inact(\'hprivacy\');"><img src="/images/rollovers/hprivacy_off.gif" width="99" height="25" border="0" alt="privacy policy" name="hprivacy"></a></td>' +
	'<td width="105"><a href="' + linkContact + '" onmouseover="img_act(\'hcontactus\');" onmouseout="img_inact(\'hcontactus\');"><img src="/images/rollovers/hcontactus_off.gif" width="79" height="25" border="0" alt="contact us" name="hcontactus"></a></td>' +
	'<td width="62"><a href="' + linkEmergency + '" onmouseover="doTooltip(event,emergency)" onMouseout="hideTip()"><img src="/images/rollovers/help.gif" width="23" height="25" border="0" alt=""></a></td>' +
	'</tr>' +
	'</table>')
}

// Popup center

IE=(navigator.appName=="Microsoft Internet Explorer");
NS=(navigator.appName=="Netscape");
bVer=parseInt(navigator.appVersion);
 
function popcenter(htmlURL) {
	 _params = "width=700,height=500,resizable=no,toolbar=no,scrollbars";
	
	if (bVer >= 4) {
		 _left = ( (screen.width-700) >>1 );
		 _top = ( (screen.height-500) >>1 );
	} else {
		 _top=60, _left=70;
	}
	if (IE) _params += ",top=" + _top + ",left=" + _left;
	else if (NS) _params += ",screenX=" + _left + ",screenY=" + _top;

	newWin = null;
	newWin = window.open(htmlURL,"popup", _params);
	if (newWin.opener==null) newWin.opener=window;
}


