/* AUTHOR: Collin Hunter */
/* CREATION DATE: 01/10/2006 */
<!--
function surfto() {
//var myindex = frmAgents.agentid.selectedIndex;
//var myindex = document.getElementByID("agentid");
var Index = document.getElementById("agentid").selectedIndex;
var myvalue = document.getElementById("agentid").options[Index].value;
//var myvalue = frmAgents.agentid.options[myindex].value; 
document.location.href = "people.asp?peopleID=" + myvalue;
}

if (window.Event) document.captureEvents(Event.MOUSEUP);
function nocontextmenu()
{
event.cancelBubble = true
event.returnValue = false;
return false;
}
function norightclick(e){
if (window.Event)
	{if (e.which == 2 || e.which == 3)
		return false;
	}
else if (event.button == 2 || event.button == 3)
	{
		event.cancelBubble = true
		event.returnValue = false;
		return false;
	}
}
document.oncontextmenu = nocontextmenu;
document.onmousedown = norightclick;

function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}
function changeImagesArray(array) {
	if (preloadFlag == true) {
		var d = document; var img;
		for (var i=0; i<array.length; i+=2) {
			img = null; var n = array[i];
			if (d.images) {img = d.images[n];}
			if (!img && d.getElementById) {img = d.getElementById(n);}
			if (img) {img.src = array[i+1];}
		}
	}
}
function changeImages() {
	changeImagesArray(changeImages.arguments);
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		pre_top_overs_02 = newImage('images/top_overs_02.jpg');
		pre_top_overs_03 = newImage('images/top_overs_03.jpg');
		pre_top_overs_04 = newImage('images/top_overs_04.jpg');
		pre_top_overs_05 = newImage('images/top_overs_05.jpg');
		pre_top_overs_06 = newImage('images/top_overs_06.jpg');
		pre_top_overs_07 = newImage('images/top_overs_07.jpg');
		pre_top_overs_08 = newImage('images/top_overs_08.jpg');
		pre_search_overs_02 = newImage('images/search_overs_02.jpg');
		pre_search_overs_03 = newImage('images/search_overs_03.jpg');
		pre_search_overs_04 = newImage('images/search_overs_04.jpg');
		pre_search_overs_05 = newImage('images/search_overs_05.jpg');
		pre_search_overs_06 = newImage('images/search_overs_06.jpg');
		pre_search_overs_07 = newImage('images/search_overs_07.jpg');
		pre_icons_overs_02 = newImage('images/icons_overs_02.jpg');
		pre_icons_overs_03 = newImage('images/icons_overs_03.jpg');
		pre_icons_overs_04 = newImage('images/icons_overs_04.jpg');
		pre_icons_overs_05 = newImage('images/icons_overs_05.jpg');
		pre_icons_overs_06 = newImage('images/icons_overs_06.jpg');
		pre_icons_overs_07 = newImage('images/icons_overs_07.jpg');
		pre_icons_overs_08 = newImage('images/icons_overs_08.jpg');
		pre_icons_overs_09 = newImage('images/icons_overs_09.jpg');
		preloadFlag = true;
	}
}

var function_window = null;
function openCalculator(w,h,menus,href,ID)
  {
  function_windowWidth = w;
  function_windowHeight = h;
  function_windowLeft = (screen.width) ? (screen.width-w)/2 : 0;
  function_windowTop = (screen.height) ? (screen.height-h)/2 : 0;

  function_settings = 'directories=no,menubar='+menus+',resizable=yes,status=no,toolbar=no,height='+function_windowHeight+',width='+function_windowWidth+',top='+function_windowTop+',left='+function_windowLeft+',scrollbars=yes';
  function_window = window.open(href+'?ID='+ID,'function_window',function_settings)

    if(function_window.focus){function_window.focus();}
  }
// Copyright information must stay intact
// FormCheck v1.10
// Copyright NavSurf.com 2002, all rights reserved
// Creative Solutions for JavaScript navigation menus, scrollers and web widgets
// Affordable Services in JavaScript consulting, customization and trouble-shooting
// Visit NavSurf.com at http://navsurf.com
function formCheck(formobj){
	// name of mandatory fields
		var fieldRequired = Array("Name", "Email");
	    var fieldDescription = Array("Name", "Email");
		
	// field description to appear in the dialog box

	
	// dialog message
	var alertMsg = "Please complete the following fields:\n";
	var l_Msg = alertMsg.length;
	
	for (var i = 0; i < fieldRequired.length; i++){
		var obj = formobj.elements[fieldRequired[i]];
		if (obj){
			if (obj.type == null){
				var blnchecked = false;
				for (var j = 0; j < obj.length; j++){
					if (obj[j].checked){
						blnchecked = true;
					}
				}
				if (!blnchecked){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				continue;
			}

			switch(obj.type){
		
			case "select-one":
				if (obj.selectedIndex == 0 || obj.options[obj.selectedIndex].text == ""){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			case "select-multiple":
				if (obj.selectedIndex == -1){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			case "text":
			case "textarea":
				if (obj.value == "" || obj.value == null){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			default:
			}
		}
	}
		
	if (alertMsg.length == l_Msg){
		return true;
	}
	else{
		alert(alertMsg);
		return false;
	}
}
//-->
