﻿function searchText(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
	if (theform.header_txtSearch.value == "Search Events & Functions"){
        theform.header_txtSearch.value = "";
    }    
}
function searchText1(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
    if (theform.header_txtSearch.value == ""){
        theform.header_txtSearch.value = "Search Events & Functions";
    }  
}
function nameText(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
    if (theform.footer1_txtName.value == "Name"){
        theform.footer1_txtName.value = "";
    }
}
function nameText1(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
	if (theform.footer1_txtName.value == ""){
       theform.footer1_txtName.value = "Name";
   }   
}
function emailText(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
    if (theform.footer1_txtEmail.value == "Email"){
        theform.footer1_txtEmail.value = "";
    }
}
function emailText1(){
    var theform;
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
		theform = document.Form1;
	}
	else {
		theform = document.forms["Form1"];
	}
	if (theform.footer1_txtEmail.value == ""){
       theform.footer1_txtEmail.value = "Email";
   }   
}
var menuLeft = 0;
function getScreenW(){
	var screenW;
	if (parseInt(navigator.appVersion)>3) {
		if (navigator.appName=="Netscape"){
			screenW = parseInt(window.innerWidth)-16;
 		}
 		if (navigator.appName.indexOf("Microsoft")!=-1) {
  			screenW = parseInt(document.documentElement.offsetWidth);
 		}
	}
	if (screenW > 880){
		screenW = (screenW - 880)/2;
	}
	else{
		screenW = 0;
	}
	return screenW;
}
function displayMenu(){
	var screenW;
	screenW = getScreenW();
	menu = document.getElementById("submenu");
	if (navigator.appName =="Microsoft Internet Explorer"){
  		menu.style.left = screenW + 335;
		menuLeft = screenW + 335;
	}
 	else{
		menu.style.left = screenW + 355 + "px";
		menuLeft = screenW + 355;
	}
	menu.style.display = "block";
	menu.style.visibility = "visible";
}
function hideMenu(){
	menu = document.getElementById("submenu");
	menu.style.display = "none";
	menu.style.visibility = "hidden";
}
var IE = document.all?true:false;
if (!IE){
	document.captureEvents(Event.MOUSEMOVE)
	document.onmousemove = hideMenu1;
}
var tempX = 0;
var tempY = 0;
function hideMenu1(e){
	if (IE) { // grab the x-y pos.s if browser is IE
		tempX = event.clientX + document.body.scrollLeft;
		tempY = event.clientY + document.body.scrollTop;
	}
	else {  // grab the x-y pos.s if browser is NS
		tempX = e.pageX;
		tempY = e.pageY;
	}  
	if (tempX < 0){tempX = 0;}
	if (tempY < 0){tempY = 0;}  
	if (parseInt(tempX) < parseInt(menuLeft)){
		hideMenu();
	}
	if (parseInt(tempX) > parseInt(menuLeft)+160){
		hideMenu();
	}
	if (tempY > 655){
		hideMenu();
	}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function printPage(CId, Type){
	window.open ("print.asp?CId=" + CId + "&type=" + Type,"print",'width=700,height=500,scrollbars=yes');
}