function animator() {
  document.visible.src = imgSrc[frame].src;
  frame = (frame + 1);
  if(frame >= i) {
    frame = 0;
    }
  timeout_state = setTimeout('animator()', 1750);
}

// -

function stopCheck() {
    clearTimeout(timeout_state);
    timeout_state = null;
  }

// -

function windowOpen(link,width,height,top,left) {
myWindow = window.open(link,'popup','resizable=yes, width=' + width + ',height=' + height+',top=' + top +',left=' + left +',screenX=' + top + ',screenY=' + left);
myWindow.focus();
myWindow.resizeTo(width,height);
if (myWindow.opener == null) mywindow.opener = self;
return false;
}
 
// -

function totop() {
	window.scrollTo(0,0)
}
if (document.layers) {
	document.captureEvents(Event.ondblclick);
}
document.ondblclick=totop;

// -

var today = new Date()
var monthArray = new Array("January", "February", "March", "April", "May", "June", "July", "August","September", "October", "November", "December")
var usdate = (monthArray[today.getMonth()] + " " +  today.getDate())
var wmdate = (today.getDate() + " " +  monthArray[today.getMonth()])
var wmmonth = (monthArray[today.getMonth()])

// -

function jmp(form, elt)
// The first parameter is a reference to the form.
{
	if (form != null) {
		with (form.elements[elt]) {
			if (0 <= selectedIndex)
				location = options[selectedIndex].value;
		}
	}
}

// -

function clearDefault(el) {
  if (el.defaultValue==el.value) el.value = ""
}

// -

function check(evt) {
	evt = (evt) ? evt : ((event) ? event : null);

	mNv=contact.YourName.value;
	if (mNv=='') {
		alert('Your name is a required field');
		if (evt.returnValue) {
			evt.returnValue=false;
		} else if (evt.preventDefault) {
			evt.preventDefault();
		} else {
			return false;
		}
	}
	mNv=contact.Email.value;
	if (mNv=='') {
		alert('Your email address is a required field');
		if (evt.returnValue) {
			evt.returnValue=false;
		} else if (evt.preventDefault) {
			evt.preventDefault();
		} else {
			return false;
		}
	}
}


// -

function check2() {
mNv=complaints.YourName.value;
if (mNv=='') {
alert('Your name is a required field');
event.returnValue=false;
}
mNv=complaints.Email.value;
if (mNv=='') {
alert('Your email address is a required field');
event.returnValue=false;
}
}


// -

function checksearch() {
kxr=document.searchform.elements['sp-q'].value;
if ((kxr=='Search site for ...') || (kxr=='')) {
return false;}
}

