/***********************************************
* Menu Script
***********************************************/
function displayMenu(currentMenu) {
var thisMenu = document.getElementById(currentMenu).style

// The above creates a new function that will expand and contract certain menus that are specified.

if (thisMenu.display == "block") {
thisMenu.display = "none"
} else {
thisMenu.display = "block"
}
return false
}
/***********************************************
* Popup Pic Script
***********************************************/

function PopupPic() {
 if (arguments[1] == null || arguments[1].length == 0 || arguments[2] == null || arguments[2].length == 0) {
  window.open( "popup.php?" + arguments[0], "", "resizable=1,HEIGHT=200,WIDTH=200"); 
 }
 else {
  window.open( "popup.php?" + arguments[0], "", "resizable=1,HEIGHT=" + arguments[2] + ",WIDTH=" + arguments[1] + ""); 
 }
} 
// Pop-up window generator
var popUpWin = null;
function popUpWindow(URLStr, left, top, width, height)
{
  if(popUpWin) { if(!popUpWin.closed) popUpWin.close();}
  popUpWin = open(URLStr, 'popUpWin', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbar=yes,resizable=yes,copyhistory=yes,width='+width+',height='+height+',left='+left+',top='+top+',screenX='+left+',screenY='+top+'');
  popUpWin.focus();
}


/***********************************************
* Popup URL Script
***********************************************/

function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=yes,location=0,statusbar=0,menubar=yes,resizable=0,width=440,height=600');");
}

function myOpen() {
    open('about:blank');}



/***********************************************
* ShowHide Script
***********************************************/

//<!--
function viewInfo(id) {
	box = document.getElementById(id);
	if(box.className == "visible") {
		box.className = "hidden";
	} else {
		box.className = "visible";
	}
}
//-->


/***********************************************
* Dropdown Fix for IE
***********************************************/

<!--//--><![CDATA[//><!--
function menuFix() {
	var sfEls = document.getElementById("select-region").getElementsByTagName("li");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		// event added to keep menu items from disappearing
		sfEls[i].onMouseDown=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		// event added to keep menu items from disappearing
		sfEls[i].onMouseUp=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		sfEls[i].onmouseout=function() {
		this.className=this.className.replace(new RegExp("( ?|^)sfhover\\b"), "");
		}
	}
}
window.onload=menuFix;
//--><!]]>


/***********************************************
* Live Support Script
***********************************************/

function ClicktoCall(id){
	var w=370;
	var h=450;
	var leftPos=(screen.width)?(screen.width-w)/2:100;
	var topPos=(screen.height)?(screen.height-h)/2:100;
	var settings='width='+w+',height='+h+',top='+topPos+',left='+leftPos+',';
	settings = settings+'location=no,directories=no,menubar=no,toolbar=no,';
	settings = settings+'status=no,scrollbars=no,resizable=no,dependent=no';
	var sUrl='http://www.nascomms.com/ccConnect/Dialer.aspx?clientId='+id;
	var ccWindow=window.open(sUrl,'ClickCalling',settings);
	ccWindow.focus();
/***********************************************
* Preload navigation rollovers
***********************************************/	

if (document.images) 
{
   img1 = new Image();
   img2 = new Image();
   img3 = new Image();
   img4 = new Image();
   img5 = new Image();
   img1.src = "images/nav/box1-on.jpg";
   img2.src = "images/nav/box2-on.jpg"
   img3.src = "images/nav/box3-on.jpg";
   img4.src = "images/nav/box4-on.jpg"
   img5.src = "images/nav/box5-on.jpg"
   
}


}
